MiDKP_Config = MiDKP_Config or {} MiDKP_Debug=false MiDKP_Config_Wrapper={ IsIdMatchCurrent=function(self,id) return MiDKP_Config["current_raid"] and MiDKP_Config["current_raid"] == id end } SLASH_MiDKP1,SLASH_MiDKP2='/midkp','/md' MIDKP_YOU_TEXT = "你" if (GetLocale() == "zhTW") then MIDKP_MESSAGE_INFO = "|cff20ff20<MiDKP 信息> |r" MIDKP_MESSAGE_ERROR = "|cffe00000<MiDKP 錯誤> |r" MIDKP_MESSAGE_DEBUG = "|cff00c0c0<MiDKP 調試> |r" MIDKP_ERROR_RAID_ALREADY_EXISTS = "團隊活動名稱<%s>已經存在。" MIDKP_INFO_CREATE_RAID = "團隊活動<%s>創建成功。" MIDKP_INFO_GREETING="MiDKP：2.11，由178游戲網（www.178.com）制作，請使用/md召喚面板" MIDKP_INFO_EVENT_ADD="已添加事件<%s>，時間為%s。" MIDKP_INFO_EVENT_POINT_ADD="已添加事件<%s>，時間為%s，分值為%g。" MIDKP_INFO_EVENT_MODIFIED="事件<%s>修改成功。" MiDKP_6700ce7638ed1dc98ada34b035892167 = { ["zones"] = { ["永恆之眼"] = true, ["黑曜聖所"] = true, ["亞夏梵穹殿"] = true, ["納克薩瑪斯"] = true, ["奧杜亞"] = true, ["十字軍試煉"]=true, }, ["bosses"] = { ["kill"] = { ["永恆之眼"] = { ["瑪裏苟斯"] = true, }, ["黑曜聖所"] = { ["撒爾薩裏安"] = true, }, ["亞夏梵穹殿"] = { ["『石之看守者』亞夏梵"] = true, ["『烈焰看守者』寇拉隆"] = true, ["『風暴看守者』艾瑪隆"] = true, }, ["納克薩瑪斯"] = { ["泰迪斯"] = true, ["葛羅巴斯"] = true, ["『不潔者』海根"] = true, ["梅克絲娜"] = true, ["大寡婦費琳娜"] = true, ["『瘟疫使者』諾斯"] = true, ["阿努比瑞克漢"] = true, ["薩菲隆"] = true, ["科爾蘇加德"] = true, ["憎恨者"] = true, ["縫補者"] = true, ["『收割者』高希"] = true, ["講師拉祖維斯"] = true, }, ["奧杜亞"] = { ["烈焰戰輪"] = true, ["XT-002拆解者"] = true, ["銳鱗"] = true, ["『火爐之主』伊格尼司"] = true, ["霍迪爾"] = true, ["索林姆"] = true, ["芙蕾雅"] = true, ["彌米倫"] = true, ["鐵之集會"] = true, ["柯洛剛恩"] = true, ["奧芮雅"] = true, ["威札斯將軍"] = true, ["尤格薩倫"] = true, ["『觀察者』艾爾加隆"] = true, }, ["十字軍試煉"] = { ["冰嚎"] = true, ["華爾琪雙子"] = true, }, ["冰冠城塞"] = { ["瑪洛嘉領主"] = true, ["亡語女士"] = true, ["砲艇軍械庫"] = true, ["死亡使者薩魯法爾"] = true, ["膿腸"] = true, ["腐臉"] = true, ["普崔希德教授"] = true, ["瓦拉納爾親王"] = true, ["血腥女王菈娜薩爾"] = true, }, }, ["multikill"] = { ["納克薩瑪斯"] = { ["四騎士"] = { ["寇斯艾茲族長"] = true, ["札裏克爵士"] = true, ["布洛莫斯女士"] = true, ["瑞文戴爾男爵"] = true, }, }, ["奧杜亞"] = { ["鐵之集會"] = { ["破鋼者"] = true, ["風暴召喚者布倫迪爾"] = true, ["符文大師墨吉姆"] = true, }, } }, ["emote"] = { ["別說我沒警告過你，無賴!兄弟姊妹們，向前衝!"]="寒冰皇冠空中艦艇戰", ["巨獸已經被參賽者擊敗了"] = "冰嚎", ["有人會代替我，你的世界注定毀滅……"] = "賈拉克瑟斯領主", ["膚淺而悲痛的勝利。今天痛失的生命反而令我們更加的頹弱。除了巫妖王之外，誰還能從中獲利?偉大的戰士失去了寶貴生命。為了什麼?真正的威脅就在前方 - 巫妖王在死亡的領域中等著我們。"] = "陣營勇士", ["誰也阻擋不了天譴軍團……"] = "華爾琪雙子", ["我讓你失望了，主人……"] = "阿努巴拉克", }, ["loot"] = { }, } } MiDKP_DefaultIgnoreItems = { "公正徽章", "獅眼石", "影歌紫玉", "天藍寶石", "赤尖石", "海浪翡翠", "焚石", "黑暗之心", "太陽之塵", "連結水晶", "大塊棱光碎片", "小塊棱光碎片", "虛空水晶", } MiDKP_Options = { ["default_member_filter"] = "first5", ["member_record_disconnected"] = true, ["min_quality"] = 3, ["default_action"] = "notify", ["whisper_command"] = "dkp", ["hide_whisper_reply"] = false, ["ignore_items"] = { "公正徽章", "獅眼石", "影歌紫玉", "天藍寶石", "赤尖石", "海浪翡翠", "焚石", "黑暗之心", "太陽之塵", "連結水晶", "大塊棱光碎片", "小塊棱光碎片", "虛空水晶", }, } MIDKP_ADDON_TITLE={"團隊DKP","tuanduiDKP",2} MIDKP_ADDON_ENABLE="使用MiDKP插件" MIDKP_TEXT_CONFIRM_DELETE_RAID = "刪除團隊活動將導致該團隊活動的所有資料都清除，你確信要這麼做嗎？" MIDKP_TEXT_CONFIRM_DELETE_MEMBER = "你確信要刪除成員<%s>嗎？" MIDKP_TEXT_CREATE_IGNORE_ITEM = "請輸入你想要創建的忽略物品的名稱" MIDKP_TEXT_CONFIRM_DELETE_IGNORE_ITEM = "你確信要刪除忽略的物品<%s>嗎？" MIDKP_TEXT_CONFIRM_RESTORE_IGNORE_ITEMS = "所有的自訂的忽略物品都將被清除，你確信要這麼做嗎？" MIDKP_TEXT_CONFIRM_DELETE_EVENT = "你確信要刪除事件<%s>嗎？" MIDKP_TEXT_CONFIRM_DELETE_ITEM = "你確信要刪除物品<%s>嗎？" MIDKP_TEXT_CONFIRM_SAVE_RAID = "該操作將重新載入當前界面，你確信要這麼做嗎？" MIDKP_TEXT_CLASS_NOT_MATCH = "添加成員職業與數據不符！" MIDKP_TEXT_TOTAL_CLASS_POINT = "參加本次活動的%s的總分為：%g。" MIDKP_TEXT_FINISH_EVENT = "完成 %s" MIDKP_TEXT_NO_RAID = "當前無活動。" MIDKP_TEXT_RAID_NO_START = "活動還沒開始。" MIDKP_TEXT_RAID_STARTED_AND_ACTIVATED="<%s>已開始并激活" MIDKP_TEXT_MAGE = "法師" MIDKP_TEXT_DRUID = "德魯伊" MIDKP_TEXT_WARRIOR = "戰士" MIDKP_TEXT_HUNTER = "獵人" MIDKP_TEXT_DEATHKNIGHT = "死亡騎士" MIDKP_TEXT_DEATHKNIGHT2 = "死騎" MIDKP_TEXT_SHAMAN = "薩滿祭司" MIDKP_TEXT_SHAMAN2 = "薩滿" MIDKP_TEXT_ROGUE = "盜賊" MIDKP_TEXT_ROGUE2 = "潛行者" MIDKP_TEXT_PRIEST = "牧師" MIDKP_TEXT_WARLOCK = "術士" MIDKP_TEXT_PALADIN = "聖騎士" MIDKP_TEXT_RAID_NAME_INFO = "本次活動為：%s" MIDKP_TEXT_EVENT_INFO = "與你有關係的事件有：" MIDKP_TEXT_EVENT_INFO2 = " %d. %s (%g分)" MIDKP_TEXT_ITEM_INFO = "你獲得的物品有：" MIDKP_TEXT_ITEM_INFO2 = " %d. %s (%g分)" MIDKP_TEXT_MEMBER_INFO = "你本次活動實際獲得的分值為%d分。" MIDKP_TEXT_MEMBER_INFO2 = "你在活動 <%s> 中擁有的總分值為%d分。" MIDKP_TEXT_MEMBER_INFO3 = "參加本次活動的%s有：" MIDKP_TEXT_MEMBER_INFO4 = " %d. %s (%g 分)" MIDKP_TEXT_MEMBER_INFO5 = "你在<%s>中擁有的總分值為%g分。" MIDKP_TEXT_MEMBER_INFO5_PLAYER = ">%s<在<%s>中擁有:%s。" MIDKP_TEXT_MEMBER_CURRENT_TOTAL = "你在<%s>中的分數為：歷史：%s分/當前：%s分。" MIDKP_TEXT_MEMBER_CURRENT_TOTAL_PLAYER = ">%s<在<%s>中的分數為：歷史：%d分/當前：%d分。" MIDKP_TEXT_RAID_NO_MEMBER_INFO = "本次活動沒有%s參加。" MIDKP_TEXT_INVALID_PLAYER = "非法的玩家名。" MIDKP_TEXT_NO_ITEM = "不存在指定的物品。" MIDKP_TEXT_ADD_MEMBER = "添加成員" MIDKP_TEXT_SUITE_RETURNED = "密語時返回分數" MIDKP_TEXT_SPLIT_ITEM_POINTS= " %s 平均分配分數" MIDKP_TEXT_EVENT_EMPTY_MEMBERS = "不能添加成員為空的活動" MIDKP_TEXT_TAB_DKP = "分數" MIDKP_TEXT_NO_MEMBER = "列表中不存在指定成員<%s>。" MIDKP_TEXT_MEMBER_INLIST = "成員<%s>已在列表中。" MIDKP_TEXT_INVALID_EVENT = "不合法的事件描述。" MIDKP_TEXT_NO_EVENT = "不存在指定的事件。" MIDKP_TEXT_CANNOT_DELETE_ITEM_EVENT= "不能刪除與物品相關的事件，請到物品欄刪除該物品！" MIDKP_TEXT_INVALID_POINT = "不合法的分值。" MIDKP_TEXT_RAID_PATTERN = "團隊活動 (" MIDKP_TEXT_NO_SPEC_RAID = "不存在指定的團隊活動。" MIDKP_TEXT_INVALID_RAID = "無效的團隊活動名稱。" MIDKP_TEXT_NO_IN_RAID = "你不在一個團隊中。" MIDKP_TEXT_RAID_ALREADY_START = "團隊活動<%s>已經開始了。" MIDKP_TEXT_ALREADY_HAS_RAID = "已經存在一個開始的團隊活動，請先結束該活動。" MIDKP_TEXT_RAID_NOT_BIND = "本次活動沒有與任何DKP係統綁定，請在活動欄進行綁定。" MIDKP_TEXT_MEMBER_INFO_HELP_MESSAGE = "使用\"dkp help\"來查看更多密語命令" MIDKP_TEXT_MEMBER_INFO_AD = "MiDKP插件由178游戲網（www.178.com）制作。" MIDKP_TEXT_MEMBER_HELP_MESSAGE_TEXT="使用\"dkp 係統編號\"來查看某套係統數據,\"dkp 職業\"來查看職業數據，比如：\"dkp 1\", \"dkp fs\"" MIDKP_TEXT_RAID_ALREADY_END = "團隊活動<%s>已經結束了。" MIDKP_TEXT_RAID_EXPORT = "匯出" MIDKP_TEXT_RAID_END = "結束" MIDKP_TEXT_RAID_START = "開始" MIDKP_TEXT_RAID_RUNNING = "(|cff008000進行中|r)" MIDKP_TEXT_RAID_STATUS_NO_START = "(|cff800000未開始|r)" MIDKP_TEXT_RAID_STATUS_END = "(|cff008080已結束|r)" MIDKP_TEXT_RAID_TOTAL_MEMBER = "總共%d人" MIDKP_TEXT_RAID_START_TIME = "開始：%s" MIDKP_TEXT_RAID_END_TIME = "，結束：%s" MIDKP_TEXT_ONLY_RAID ="只查看團隊成員" MIDKP_TEXT_DAY = "天" MIDKP_TEXT_HOUR = "小時" MIDKP_TEXT_MINUTE = "分鐘" MIDKP_TEXT_SECOND = "秒" MIDKP_TEXT_TAB_RAID = "活動" MIDKP_TEXT_TAB_MEMBER = "人員" MIDKP_TEXT_TAB_EVENT = "事件" MIDKP_TEXT_TAB_ITEM = "物品" MIDKP_TEXT_TAB_OPTION = "選項" MIDKP_TEXT_TAB_DKP = "分數" MIDKP_TEXT_ANNOUNCE_CONFIG="配置" MIDKP_TEXT_MODIFY_EVENT = "修改事件" MIDKP_TEXT_ADD_EVENT = "添加事件" MIDKP_TEXT_MODIFY_ITEM = "修改物品" MIDKP_TEXT_ADD_TO_LIST="添加到忽略" MIDKP_TEXT_ADD_ITEM = "添加物品" MIDKP_TEXT_AWAY = "|cff808080(離)|r" MIDKP_TEXT_OFFLINE = "|cff800000(斷)|r" MIDKP_TEXT_ANNOUNCE_1 = "活動<%s>時長為%s。" MIDKP_TEXT_ANNOUNCE_2 = "發生的事件有：" MIDKP_TEXT_ANNOUNCE_3 = "獲得的物品有：" MIDKP_TEXT_ANNOUNCE_4 = " %d. %s (%d 分)" MIDKP_TEXT_ANNOUNCE_5 = " %d. %s (%s 獲得)(%d 分)" MIDKP_TEXT_ANNOUNCE_6 = "無人" MIDKP_TEXT_ANNOUNCE_7 = "人員有：" MIDKP_TEXT_ANNOUNCE_8 = " %d. %s (历史：%g分/当前：%g 分)" MIDKP_TEXT_ANNOUNCE_9 = " %d. %s (%g 分)" MIDKP_TEXT_ANNOUNCE_10 = "活動 %s 得分：" MIDKP_TEXT_MODIFY_RAID = "修改活動" MIDKP_TEXT_CREATE_RAID = "創建活動" MIDKP_TEXT_SPECIFY_RAID = "請指定活動名稱。" MIDKP_TEXT_ANNOUNCE_TEXT = "發佈" MIDKP_TEXT_MODIFY = "修改" MIDKP_TEXT_CREATE = "創建" MIDKP_TEXT_DELETE = "刪除" MIDKP_TEXT_PREV_PAGE = "上一頁" MIDKP_TEXT_NEXT_PAGE = "下一頁" MIDKP_TEXT_ADD_EVENT = "添加事件" MIDKP_TEXT_OPTION_POINTS_DIST = "分數分配方法" MIDKP_TEXT_OPTION_1 = "記錄的物品的最低品質" MIDKP_TEXT_OPTION_2 = "玩家密語查詢功能" MIDKP_TEXT_OPTION_3 = "產生事件時觸發的動作" MIDKP_TEXT_OPTION_4 = "產生事件時預設記錄的人員" MIDKP_TEXT_OPTION_5 = "忽略的物品" MIDKP_TEXT_OPTION_6 = "優秀" MIDKP_TEXT_OPTION_7 = "精良" MIDKP_TEXT_OPTION_8 = "史詩" MIDKP_TEXT_OPTION_9 = "傳奇" MIDKP_TEXT_OPTION_10 = "密語查詢命令" MIDKP_TEXT_OPTION_11 = "不顯示返回給玩家的密語資訊" MIDKP_TEXT_OPTION_12 = "不產生動作" MIDKP_TEXT_OPTION_13 = "僅顯示提示" MIDKP_TEXT_OPTION_14 = "彈出修改介面" MIDKP_TEXT_OPTION_15 = "前五組成員" MIDKP_TEXT_OPTION_16 = "團隊成員" MIDKP_TEXT_OPTION_17 = "所有成員" MIDKP_TEXT_OPTION_18 = "包含狀態為斷線的成員" MIDKP_TEXT_OPTION_19 = "物品分數平均分配到隊員" MIDKP_TEXT_ANNOUCNE_INFO = "發佈資訊" MIDKP_TEXT_ANNOUCNE_CHANNEL = "發佈頻道" MIDKP_TEXT_INFORMATION = "資訊內容" MIDKP_TEXT_RAID_CHANNEL = "團隊頻道" MIDKP_TEXT_GUILD_CHANNEL = "公會頻道" MIDKP_TEXT_OFFICER_CHANNEL = "官員頻道" MIDKP_TEXT_PARTY_CHANNEL = "小隊頻道" MIDKP_TEXT_ANNOUNCE_EVENT = "發佈事件資訊" MIDKP_TEXT_ANNOUNCE_ITEM = "發佈物品資訊" MIDKP_TEXT_ANNOUNCE_MEMBER = "發佈成員資訊" MIDKP_TEXT_ALL_MEMBERS = "所有成員" MIDKP_TEXT_ARMOR = "按防具類別劃分" MIDKP_TEXT_PLATE = "鎧甲" MIDKP_TEXT_MAIL = "鏈甲" MIDKP_TEXT_LEATHER = "皮甲" MIDKP_TEXT_CLOTH = "布甲" MIDKP_TEXT_UNKNOWN = "未知職業" MIDKP_TEXT_OK = "確定" MIDKP_TEXT_CANCEL = "取消" MIDKP_TEXT_NAME = "名稱" MIDKP_TEXT_SAVE = "保存" MIDKP_TEXT_POINT = "分值" MIDKP_TEXT_FIRST5 = "團隊前5組" MIDKP_TEXT_RAID_ALL = "團隊所有成員" MIDKP_TEXT_ALL = "活動所有成員" MIDKP_TEXT_ADD = "添加" MIDKP_TEXT_DEFAULT = "默認" MIDKP_TEXT_DKP = "DKP係統" MIDKP_TEXT_ACTIVE = "激活" MIDKP_TEXT_NO_RECORD = "你在DKP係統<%s>中沒有分值" MIDKP_TEXT_JOIN_TIME = "入團：" MIDKP_TEXT_LEAVE_TIME = "離團：" MIDKP_TEXT_CLASS = "職業" MIDKP_TEXT_CREATEMEMBER = "添加成員" MIDKP_TEXT_EVENT_BOSS = "BOSS擊殺" MIDKP_TEXT_EVENT_HAPPENS = "發生於 %s" MIDKP_TEXT_POINTS_SHORT = "%g 分" MIDKP_TEXT_POINTS = "獲得 %g " MIDKP_TEXT_ACCQUIRE="%s 獲得" MIDKP_TEXT_TOTAL_POINTS="當前分 %g" MIDKP_TEXT_TOTAL_POINTS_HIST="歷史分 %g" MIDKP_TEXT_CHANGE_RAID="當前活動已經變更為[%s]。" MIDKP_TEXT_MEMBER_NON_EXIST="請選擇一位成員" MIDKP_TEXT_CURRENT_DKP="此次活動DKP分數" MIDKP_TEXT_DKP_TITLE="DKP分數" MIDKP_TEXT_SORT_NAME="按姓名排序" MIDKP_TEXT_SORT_DKP="獲得分排序" MIDKP_TEXT_SORT_TOTALDKP="當前分排序" MIDKP_TEXT_PLAYER_DEAD="你已經死亡" MIDKP_TEXT_ANNOUNCE_PLAYER_PERSON="發送給個人" MIDKP_TEXT_ANNOUNCE_PLAYER_PARTY="發布到小隊" MIDKP_TEXT_ANNOUNCE_PLAYER_GUILD="發布到公會" MIDKP_TEXT_ANNOUNCE_PLAYER_RAID="發佈到團隊" else MIDKP_MESSAGE_INFO = "|cff20ff20<MiDKP 信息> |r" MIDKP_MESSAGE_ERROR = "|cffe00000<MiDKP 错误> |r" MIDKP_MESSAGE_DEBUG = "|cff00c0c0<MiDKP 调试> |r" MIDKP_ERROR_RAID_ALREADY_EXISTS = "团队活动名称<%s>已经存在。" MIDKP_INFO_CREATE_RAID = "团队活动<%s>创建成功。" MIDKP_INFO_GREETING="MiDKP：2.11，由178游戏网（www.178.com）制作，请使用/md召唤面板" MIDKP_INFO_EVENT_ADD="已添加事件<%s>，时间为%s。" MIDKP_INFO_EVENT_POINT_ADD="已添加事件<%s>，时间为%s，分值为%g。" MIDKP_INFO_EVENT_MODIFIED="事件<%s>修改成功。" MiDKP_6700ce7638ed1dc98ada34b035892167 = { ["zones"] = { ["祖阿曼"] = true, ["卡拉赞"] = true, ["海加尔峰"] = true, ["太阳之井高地"] = true, ["黑暗神殿"] = true, ["毒蛇神殿"] = true, ["风暴要塞"] = true, }, ["bosses"] = { ["kill"] = { ["卡拉赞"] = { ["猎手阿图门"] = true, ["莫罗斯"] = true, ["贞节圣女"] = true, ["大灰狼"] = "歌剧院", ["巫婆"] = "歌剧院", ["馆长"] = true, ["特雷斯坦·邪蹄"] = true, ["埃兰之影"] = true, ["虚空幽龙"] = true, ["玛克扎尔王子"] = true, ["夜之魇"] = true, ["蹂躏者洛卡德"] = true, ["潜伏者希亚其斯"] = true, ["滑翔者沙德基斯"] = true, }, ["毒蛇神殿"] = { ["不稳定的海度斯"] = true, ["鱼斯拉"] = true, ["盲眼者莱欧瑟拉斯"] = true, ["深水领主卡拉瑟雷斯"] = true, ["莫洛格里·踏潮者"] = true, ["瓦丝琪"] = true, }, ["风暴要塞"] = { ["奥"] = true, ["空灵机甲"] = true, ["大星术师索兰莉安"] = true, ["凯尔萨斯·逐日者"] = true, }, ["祖阿曼"] = { ["纳洛拉克"] = true, ["埃基尔松"] = true, ["哈尔拉兹"] = true, ["加亚莱"] = true, ["妖术领主玛拉卡斯"] = true, ["祖尔金"] = true, }, ["海加尔峰"] = { ["雷基·冬寒"] = true, ["安纳塞隆"] = true, ["卡兹洛加"] = true, ["阿兹加洛"] = true, ["阿克蒙德"] = true, }, ["黑暗神殿"] = { ["高阶督军纳因图斯"] = true, ["苏普雷姆斯"] = true, ["阿卡玛之影"] = true, ["塔隆·血魔"] = true, ["古尔图格·血沸"] = true, ["愤怒精华"] = "灵魂之匣", ["莎赫拉丝主母"] = true, ["伊利达雷议会"] = true, ["伊利丹·怒风"] = true, }, ["太阳之井高地"] = { ["布鲁塔卢斯"] = true, ["菲米丝"] = true, ["熵魔"] = "穆鲁", ["基尔加丹"] = true, }, ["怒焰裂谷"] = MiDKP_Debug and { ["玛尔·恐怖图腾"] = true, ["祈求者耶戈什"] = true, ["饥饿者塔拉加曼"] = true, ["巴扎兰"] = true, ["熔岩元素"] = true, ["钻土虫"] = true, ["怒焰穴居人"] = true, }, }, ["multikill"] = { ["太阳之井高地"] = { ["艾瑞达双子"] = { ["高阶术士奥蕾塞丝"] = true, ["萨洛拉丝女王"] = true, }, }, }, ["emote"] = { ["不……不可能！等一下……我投降！我投降！"] = "管理者埃克索图斯", ["当附着在象棋大厅门上的诅咒被驱散的同时，卡拉赞的大厅也开始剧烈的颤抖。"] = "国际象棋", ["我欠你们一份情。当我们战胜基尔加丹时，整个世界都会感激你们的。"] = "卡雷苟斯", ["我绝不会落到……输的……那一边。"] = "卡雷苟斯", }, ["loot"] = { }, } } MiDKP_DefaultIgnoreItems = { "公正徽章", "狮眼石", "影歌紫玉", "天蓝宝石", "赤尖石", "海浪翡翠", "焚石", "黑暗之心", "太阳之尘", "连结水晶", "大块棱光碎片", "小块棱光碎片", "虚空水晶", } MiDKP_Options = { ["default_member_filter"] = "first5", ["member_record_disconnected"] = true, ["min_quality"] = 3, ["default_action"] = "notify", ["whisper_command"] = "dkp", ["hide_whisper_reply"] = true, ["show_raid_only"] = 0, ["ignore_items"] = { "公正徽章", "狮眼石", "影歌紫玉", "天蓝宝石", "赤尖石", "海浪翡翠", "焚石", "黑暗之心", "太阳之尘", "连结水晶", "大块棱光碎片", "小块棱光碎片", "虚空水晶", }, } MIDKP_ADDON_TITLE={"团队DKP","tuanduiDKP",2} MIDKP_ADDON_ENABLE="使用MiDKP插件" MIDKP_TEXT_CONFIRM_DELETE_RAID = "删除团队活动将导致该团队活动的所有数据都清除，你确信要这么做吗？" MIDKP_TEXT_CONFIRM_DELETE_MEMBER = "你确信要删除成员<%s>吗？" MIDKP_TEXT_CREATE_IGNORE_ITEM = "请输入你想要创建的忽略物品的名称" MIDKP_TEXT_CONFIRM_DELETE_IGNORE_ITEM = "你确信要删除忽略的物品<%s>吗？" MIDKP_TEXT_CONFIRM_RESTORE_IGNORE_ITEMS = "所有的自定义的忽略物品都将被清除，你确信要这么做吗？" MIDKP_TEXT_CONFIRM_DELETE_EVENT = "你确信要删除事件<%s>吗？" MIDKP_TEXT_CONFIRM_DELETE_ITEM = "你确信要删除物品<%s>吗？" MIDKP_TEXT_CONFIRM_SAVE_RAID = "该操作将重载当前界面，你确信要这么做吗？" MIDKP_TEXT_CLASS_NOT_MATCH = "添加成员职业与数据不符！" MIDKP_TEXT_TOTAL_CLASS_POINT = "参加本次活动的%s的总分为：%g。" MIDKP_TEXT_FINISH_EVENT = "完成 %s" MIDKP_TEXT_NO_RAID = "当前无活动。" MIDKP_TEXT_RAID_NO_START = "活动还没开始。" MIDKP_TEXT_RAID_STARTED_AND_ACTIVATED="<%s>已开始并激活" MIDKP_TEXT_MAGE = "法师" MIDKP_TEXT_DRUID = "德鲁伊" MIDKP_TEXT_WARRIOR = "战士" MIDKP_TEXT_HUNTER = "猎人" MIDKP_TEXT_DEATHKNIGHT = "死亡骑士" MIDKP_TEXT_DEATHKNIGHT2 = "死骑" MIDKP_TEXT_SHAMAN = "萨满祭司" MIDKP_TEXT_SHAMAN2 = "萨满" MIDKP_TEXT_ROGUE = "潜行者" MIDKP_TEXT_ROGUE2 = "盗贼" MIDKP_TEXT_PRIEST = "牧师" MIDKP_TEXT_WARLOCK = "术士" MIDKP_TEXT_PALADIN = "圣骑士" MIDKP_TEXT_RAID_NAME_INFO = "本次活动为：%s" MIDKP_TEXT_EVENT_INFO = "与你有关系的事件有：" MIDKP_TEXT_EVENT_INFO2 = " %d. %s (%g分)" MIDKP_TEXT_ITEM_INFO = "你获得的物品有：" MIDKP_TEXT_ITEM_INFO2 = " %d. %s (%g分)" MIDKP_TEXT_MEMBER_INFO = "你本次活动实际获得的分值为%d分。" MIDKP_TEXT_MEMBER_INFO2 = "你在活动 <%s> 的总分值为%d分。" MIDKP_TEXT_MEMBER_INFO3 = "参加本次活动的%s有：" MIDKP_TEXT_MEMBER_INFO4 = " %d. %s (%g 分)" MIDKP_TEXT_MEMBER_INFO5 = "你在<%s>中拥有的总分值为%g分。" MIDKP_TEXT_MEMBER_INFO5_PLAYER = ">%s<在<%s>中拥有:%s。" MIDKP_TEXT_MEMBER_CURRENT_TOTAL = "你在<%s>中的分数为：历史：%s分/当前：%s分。" MIDKP_TEXT_MEMBER_CURRENT_TOTAL_PLAYER = ">%s<在<%s>中的分数为：历史：%d分/当前：%d分。" MIDKP_TEXT_RAID_NO_MEMBER_INFO = "本次活动没有%s参加。" MIDKP_TEXT_INVALID_PLAYER = "非法的玩家名。" MIDKP_TEXT_NO_ITEM = "不存在指定的物品。" MIDKP_TEXT_ADD_MEMBER = "添加成员" MIDKP_TEXT_SUITE_RETURNED = "密语时返回分数" MIDKP_TEXT_SPLIT_ITEM_POINTS= " %s 平均分配分数" MIDKP_TEXT_EVENT_EMPTY_MEMBERS = "不能添加成员为空的活动" MIDKP_TEXT_TAB_DKP = "分数" MIDKP_TEXT_NO_MEMBER = "列表中不存在指定成员<%s>。" MIDKP_TEXT_MEMBER_INLIST = "成员<%s>已在列表中。" MIDKP_TEXT_INVALID_EVENT = "不合法的事件描述。" MIDKP_TEXT_NO_EVENT = "不存在指定的事件。" MIDKP_TEXT_CANNOT_DELETE_ITEM_EVENT= "不能删除与物品相关的事件，请到物品栏删除该物品！" MIDKP_TEXT_INVALID_POINT = "不合法的分值。" MIDKP_TEXT_RAID_PATTERN = "团队活动 (" MIDKP_TEXT_NO_SPEC_RAID = "不存在指定的团队活动。" MIDKP_TEXT_INVALID_RAID = "无效的团队活动名称。" MIDKP_TEXT_NO_IN_RAID = "你不在一个团队中。" MIDKP_TEXT_RAID_ALREADY_START = "团队活动<%s>已经开始了。" MIDKP_TEXT_ALREADY_HAS_RAID = "已经存在一个开始的团队活动，请先结束该活动。" MIDKP_TEXT_RAID_NOT_BIND = "本次活动没有与任何DKP系统绑定，请在活动栏内进行绑定。" MIDKP_TEXT_MEMBER_INFO_HELP_MESSAGE = "使用\"dkp help\"来查看更多密语命令" MIDKP_TEXT_MEMBER_HELP_MESSAGE_TEXT="使用\"dkp 系统编号\"来查看某套系统数据,\"dkp 职业\"来查看职业数据，比如：\"dkp 1\", \"dkp fs\"" MIDKP_TEXT_MEMBER_INFO_AD = "MiDKP插件由178游戏网（www.178.com）制作。" MIDKP_TEXT_RAID_ALREADY_END = "团队活动<%s>已经结束了。" MIDKP_TEXT_RAID_EXPORT = "导出" MIDKP_TEXT_RAID_END = "结束" MIDKP_TEXT_RAID_START = "开始" MIDKP_TEXT_RAID_RUNNING = "(|cff008000进行中|r)" MIDKP_TEXT_RAID_STATUS_NO_START = "(|cff800000未开始|r)" MIDKP_TEXT_RAID_STATUS_END = "(|cff008080已结束|r)" MIDKP_TEXT_RAID_TOTAL_MEMBER = "总共%d人" MIDKP_TEXT_RAID_START_TIME = "开始：%s" MIDKP_TEXT_RAID_END_TIME = "，结束：%s" MIDKP_TEXT_ONLY_RAID ="只查看团队人员" MIDKP_TEXT_DAY = "天" MIDKP_TEXT_HOUR = "小时" MIDKP_TEXT_MINUTE = "分钟" MIDKP_TEXT_SECOND = "秒" MIDKP_TEXT_TAB_RAID = "活动" MIDKP_TEXT_TAB_MEMBER = "人员" MIDKP_TEXT_TAB_EVENT = "事件" MIDKP_TEXT_TAB_ITEM = "物品" MIDKP_TEXT_TAB_OPTION = "选项" MIDKP_TEXT_TAB_DKP = "分数" MIDKP_TEXT_ANNOUNCE_CONFIG="配置" MIDKP_TEXT_MODIFY_EVENT = "修改事件" MIDKP_TEXT_ADD_EVENT = "添加事件" MIDKP_TEXT_MODIFY_ITEM = "修改物品" MIDKP_TEXT_ADD_TO_LIST="添加到忽略" MIDKP_TEXT_ADD_ITEM = "添加物品" MIDKP_TEXT_AWAY = "|cff808080(离)|r" MIDKP_TEXT_OFFLINE = "|cff800000(断)|r" MIDKP_TEXT_ANNOUNCE_1 = "活动<%s>时长为%s。" MIDKP_TEXT_ANNOUNCE_2 = "发生的事件有：" MIDKP_TEXT_ANNOUNCE_3 = "获得的物品有：" MIDKP_TEXT_ANNOUNCE_4 = " %d. %s (%d 分)" MIDKP_TEXT_ANNOUNCE_5 = " %d. %s (%s 获得)(%d 分)" MIDKP_TEXT_ANNOUNCE_6 = "无人" MIDKP_TEXT_ANNOUNCE_7 = "人员有：" MIDKP_TEXT_ANNOUNCE_8 = " %d. %s (历史：%g 分/当前：%g 分)" MIDKP_TEXT_ANNOUNCE_9 = " %d. %s (%g 分)" MIDKP_TEXT_ANNOUNCE_10 = "活动 %s 得分：" MIDKP_TEXT_MODIFY_RAID = "修改活动" MIDKP_TEXT_CREATE_RAID = "创建活动" MIDKP_TEXT_SPECIFY_RAID = "请指定活动名称。" MIDKP_TEXT_ANNOUNCE_TEXT = "发布" MIDKP_TEXT_MODIFY = "修改" MIDKP_TEXT_CREATE = "创建" MIDKP_TEXT_DELETE = "删除" MIDKP_TEXT_PREV_PAGE = "上一页" MIDKP_TEXT_NEXT_PAGE = "下一页" MIDKP_TEXT_ADD_EVENT = "添加事件" MIDKP_TEXT_OPTION_POINTS_DIST = "分数分配方法" MIDKP_TEXT_OPTION_1 = "记录的物品的最低品质" MIDKP_TEXT_OPTION_2 = "玩家密语查询功能" MIDKP_TEXT_OPTION_3 = "产生事件时触发的动作" MIDKP_TEXT_OPTION_4 = "产生事件时默认记录的人员" MIDKP_TEXT_OPTION_5 = "忽略的物品" MIDKP_TEXT_OPTION_6 = "优秀" MIDKP_TEXT_OPTION_7 = "精良" MIDKP_TEXT_OPTION_8 = "史诗" MIDKP_TEXT_OPTION_9 = "传奇" MIDKP_TEXT_OPTION_10 = "密语查询命令" MIDKP_TEXT_OPTION_11 = "不显示返回给玩家的密语信息" MIDKP_TEXT_OPTION_12 = "不产生动作" MIDKP_TEXT_OPTION_13 = "仅显示提示" MIDKP_TEXT_OPTION_14 = "弹出修改界面" MIDKP_TEXT_OPTION_15 = "前五组成员" MIDKP_TEXT_OPTION_16 = "团队成员" MIDKP_TEXT_OPTION_17 = "所有成员" MIDKP_TEXT_OPTION_18 = "包含状态为断线的成员" MIDKP_TEXT_OPTION_19 = "物品分数平均分配到队员" MIDKP_TEXT_ANNOUCNE_INFO = "发布信息" MIDKP_TEXT_ANNOUCNE_CHANNEL = "发布频道" MIDKP_TEXT_INFORMATION = "信息内容" MIDKP_TEXT_RAID_CHANNEL = "团队频道" MIDKP_TEXT_GUILD_CHANNEL = "公会频道" MIDKP_TEXT_OFFICER_CHANNEL = "官员频道" MIDKP_TEXT_PARTY_CHANNEL = "小队频道" MIDKP_TEXT_ANNOUNCE_EVENT = "发布事件信息" MIDKP_TEXT_ANNOUNCE_ITEM = "发布物品信息" MIDKP_TEXT_ANNOUNCE_MEMBER = "发布成员信息" MIDKP_TEXT_ALL_MEMBERS = "所有成员" MIDKP_TEXT_ARMOR = "按防具类别划分" MIDKP_TEXT_PLATE = "板甲" MIDKP_TEXT_MAIL = "锁甲" MIDKP_TEXT_LEATHER = "皮甲" MIDKP_TEXT_CLOTH = "布甲" MIDKP_TEXT_UNKNOWN = "未知职业" MIDKP_TEXT_OK = "确定" MIDKP_TEXT_CANCEL = "取消" MIDKP_TEXT_NAME = "名称" MIDKP_TEXT_SAVE = "保存" MIDKP_TEXT_POINT = "分值" MIDKP_TEXT_FIRST5 = "团队前5组" MIDKP_TEXT_RAID_ALL = "团队所有成员" MIDKP_TEXT_ALL = "活动所有成员" MIDKP_TEXT_ADD = "添加" MIDKP_TEXT_DEFAULT = "默认" MIDKP_TEXT_DKP = "DKP系统" MIDKP_TEXT_ACTIVE = "激活" MIDKP_TEXT_NO_RECORD = "你在DKP系统<%s>中没有分值" MIDKP_TEXT_JOIN_TIME = "入团：" MIDKP_TEXT_LEAVE_TIME = "离团：" MIDKP_TEXT_CLASS = "职业" MIDKP_TEXT_CREATEMEMBER = "添加成员" MIDKP_TEXT_EVENT_BOSS = "BOSS击杀" MIDKP_TEXT_EVENT_HAPPENS = "发生于 %s" MIDKP_TEXT_POINTS_SHORT = "%g分" MIDKP_TEXT_POINTS = "获得 %g" MIDKP_TEXT_ACCQUIRE="%s 获得" MIDKP_TEXT_TOTAL_POINTS="当前分 %g" MIDKP_TEXT_TOTAL_POINTS_HIST="历史分 %g" MIDKP_TEXT_CHANGE_RAID="当前团队活动已经变更为[%s]。" MIDKP_TEXT_MEMBER_NON_EXIST="请选择一位成员" MIDKP_TEXT_CURRENT_DKP="此次活动DKP分数" MIDKP_TEXT_DKP_TITLE="DKP分数" MIDKP_TEXT_SORT_NAME="按姓名排序" MIDKP_TEXT_SORT_DKP="获得分排序" MIDKP_TEXT_SORT_TOTALDKP="当前分排序" MIDKP_TEXT_PLAYER_DEAD="你已经死亡" MIDKP_TEXT_ANNOUNCE_PLAYER_PERSON="发送给个人" MIDKP_TEXT_ANNOUNCE_PLAYER_PARTY="发布到小队" MIDKP_TEXT_ANNOUNCE_PLAYER_GUILD="发布到公会" MIDKP_TEXT_ANNOUNCE_PLAYER_RAID="发布到团队" end MIDKP_RAID_PAGE_COUNT = 8 MIDKP_EVENT_PAGE_COUNT = 14 MIDKP_ITEM_PAGE_COUNT = 14 MIDKP_MEMBER_PAGE_COUNT = 14 MIDKP_DKP_PAGE_COUNT = 14 MIDKP_CLASS={ MAGE={name="MAGE",color="cff69CCF0",shortcut="fs",text1=MIDKP_TEXT_MAGE,text2=MIDKP_TEXT_MAGE,PARENT="Cloth"}, DRUID={name="DRUID",color="cffFF7D0A",shortcut="dly",text1=MIDKP_TEXT_DRUID,text2=MIDKP_TEXT_DRUID,PARENT="Leather"}, HUNTER={name="HUNTER",color="cffABD473",shortcut="lr",text1=MIDKP_TEXT_HUNTER,text2=MIDKP_TEXT_HUNTER,PARENT="Mail"}, PALADIN={name="PALADIN",color="cffF58CBA",shortcut="qs",text1=MIDKP_TEXT_PALADIN,text2=MIDKP_TEXT_PALADIN,PARENT="Plate"}, PRIEST={name="PRIEST",color="cffFFFFFF",shortcut="ms",text1=MIDKP_TEXT_PRIEST,text2=MIDKP_TEXT_PRIEST,PARENT="Cloth"}, ROGUE={name="ROGUE",color="cffFFF569",shortcut="dz",text1=MIDKP_TEXT_ROGUE,text2=MIDKP_TEXT_ROGUE2,PARENT="Leather"}, SHAMAN={name="SHAMAN",color="cff2459FF",shortcut="sm",text1=MIDKP_TEXT_SHAMAN,text2=MIDKP_TEXT_SHAMAN2,PARENT="Mail"}, WARLOCK={name="WARLOCK",color="cff9482C9",shortcut="ss",text1=MIDKP_TEXT_WARLOCK,text2=MIDKP_TEXT_WARLOCK,PARENT="Cloth"}, WARRIOR={name="WARRIOR",color="cffC79C6E",shortcut="zs",text1=MIDKP_TEXT_WARRIOR,text2=MIDKP_TEXT_WARRIOR,PARENT="Plate"}, DEATHKNIGHT={name="DEATHKNIGHT",color="cffC41F3B",shortcut="sq",text1=MIDKP_TEXT_DEATHKNIGHT,text2=MIDKP_TEXT_DEATHKNIGHT1,PARENT="Plate"}, UNKNOWN={name="UNKNOWN",color="cffDDDDDD",shortcut="wz",text1=MIDKP_TEXT_UNKNOWN,text2=MIDKP_TEXT_UNKNOWN,PARENT=""}, NAME={ "Warrior", "Paladin", "Hunter", "Rogue", "Priest", "Mage", "Druid", "Warlock", "Shaman", "DeathKnight", "UNKNOWN" }, } MIDKP_ARMOR={ NAME={ "Plate", "Mail", "Leather", "Cloth", }, TEXT={ Plate=MIDKP_TEXT_PLATE, Mail=MIDKP_TEXT_MAIL, Leather=MIDKP_TEXT_LEATHER, Cloth=MIDKP_TEXT_CLOTH, }, CLASS={ Plate={"WARRIOR","DEATHKNIGHT","PALADIN"}, Mail={"SHAMAN","HUNTER"}, Leather={"DRUID","ROGUE"}, Cloth={"MAGE","PRIEST","WARLOCK"}, } } MIDKP_LOCATIONS={ "HighlightTopLeft", "HighlightTopRight", "HighlightTop", "HighlightBottomLeft", "HighlightBottomRight", "HighlightBottom", "HighlightLeft", "HighlightRight", } MIDKP_ITEM_COLOR = { [0] = { r = 0.8, g = 0.8, b = 0.8, a = 0.8}, [1] = { r = 0.5, g = 0.5, b = 0.5, a = 0.8}, [2] = { r = 0, g = 1.0, b = 0, a = 0.8}, [3] = { r = 0, g = 0.0, b = 1.0, a = 0.8}, [4] = { r = 0.5, g = 0, b = 1.0, a = 0.8}, [5] = { r = 1.0, g = 0.5, b = 0, a = 0.8}, [6] = { r = 1.0, g = 0.5, b = 0, a = 0.8}, [9] = { r = 1, g = 1, b = 0, a = 0.6 }, } MiDKP_RequestList = {} MiDKP_BossKillTemp = {} MiDKP_HiddenWhisper = {} MiDKP_AFKDND = {} MiDKP_IgnoreItems = {} MiDKP_DIALOG_CONFIRM_DELETE_RAID="CONFIRM_DELETE_RAID" MiDKP_DIALOG_CONFIRM_DELETE_MEMBER="CONFIRM_DELETE_MEMBER" MiDKP_DIALOG_CREATE_IGNORE_ITEM="CREATE_IGNORE_ITEM" MiDKP_DIALOG_CONFIRM_DELETE_IGNORE_ITEM="CONFIRM_DELETE_IGNORE_ITEM" MiDKP_DIALOG_CONFIRM_RESTORE_IGNORE_ITEMS="CONFIRM_RESTORE_IGNORE_ITEMS" MiDKP_DIALOG_CONFIRM_DELETE_EVENT="MIDKP_CONFIRM_DELETE_EVENT" MiDKP_DIALOG_CONFIRM_DELETE_ITEM="MIDKP_CONFIRM_DELETE_ITEM" MiDKP_DIALOG_CONFIRM_SAVE_RAID="MIDKP_CONFIRM_SAVE_RAID" StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_SAVE_RAID] = { text = MIDKP_TEXT_CONFIRM_SAVE_RAID, button1 = YES, button2 = NO, OnAccept = function() ReloadUI() end, OnCancel = function() end, OnShow = function() end, OnHide = function() MiDKP_UIHelp.Util.MainFrame_Enable(true) end, timeout = 0, hideOnEscape = 1, } StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_RAID] = { text = MIDKP_TEXT_CONFIRM_DELETE_RAID, button1 = YES, button2 = NO, OnAccept = function() local id = StaticPopupDialogs["CONFIRM_DELETE_RAID"].raid_id MiDKP_Core.Raid.DeleteRaid("@"..id) if (MiDKPRaidPage:IsShown()) then MiDKP_UIHelp.Raid.DoUpdate() end end, OnCancel = function() end, OnShow = function() end, OnHide = function() MiDKP_UIHelp.Util.MainFrame_Enable(true) end, timeout = 0, hideOnEscape = 1, } StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_MEMBER] = { text = MIDKP_TEXT_CONFIRM_DELETE_MEMBER, button1 = YES, button2 = NO, OnAccept = function() local name = StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_MEMBER].member_name if (name) then MiDKP_Core.Member.DeleteMember(name) if (MiDKPMemberPage:IsShown()) then MiDKP_UIHelp.Member.DoUpdate() end end end, OnCancel = function() end, OnShow = function() end, OnHide = function() MiDKP_UIHelp.Util.MainFrame_Enable(true) end, timeout = 0, hideOnEscape = 1, } StaticPopupDialogs[MiDKP_DIALOG_CREATE_IGNORE_ITEM] = { text = MIDKP_TEXT_CREATE_IGNORE_ITEM, button1 = YES, button2 = NO, hasEditBox = 1, maxLetters = 24, OnAccept = function(self) local text = self.editBox:GetText() MiDKP_Core.Item.AddIgnoreItem(text) MiDKP_UIHelp.IgnoreItem.DoUpdate() end, OnCancel = function() end, OnShow = function() end, OnHide = function() MiDKP_UIHelp.Util.MainFrame_Enable(true) end, timeout = 0, hideOnEscape = 1, } StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_IGNORE_ITEM] = { text = MIDKP_TEXT_CONFIRM_DELETE_IGNORE_ITEM, button1 = YES, button2 = NO, OnAccept = function() local __index = StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_IGNORE_ITEM].index MiDKP_Core.Item.DeleteIgnoreItem(__index) MiDKP_UIHelp.IgnoreItem.DoUpdate() end, OnCancel = function() end, OnShow = function() end, OnHide = function() end, timeout = 0, hideOnEscape = 1, } StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_RESTORE_IGNORE_ITEMS] = { text = MIDKP_TEXT_CONFIRM_RESTORE_IGNORE_ITEMS, button1 = YES, button2 = NO, OnAccept = function() local k, v MiDKP_Options["ignore_items"] = {} for k, v in ipairs(MiDKP_DefaultIgnoreItems) do table.insert(MiDKP_Options["ignore_items"], v) end MiDKP_UIHelp.IgnoreItem.DoUpdate() end, OnCancel = function() end, OnShow = function() end, OnHide = function() end, timeout = 0, hideOnEscape = 1, } StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_EVENT] = { text = MIDKP_TEXT_CONFIRM_DELETE_EVENT, button1 = YES, button2 = NO, OnAccept = function() local id = StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_EVENT].event_id if (id) then MiDKP_Core.Raid.DeleteEvent("@"..id) if (MiDKPEventPage:IsShown()) then MiDKP_UIHelp.Event.DoUpdate() end end end, OnCancel = function() end, OnShow = function() end, OnHide = function() MiDKP_UIHelp.Util.MainFrame_Enable(true) end, timeout = 0, hideOnEscape = 1, } StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_ITEM] = { text = MIDKP_TEXT_CONFIRM_DELETE_ITEM, button1 = YES, button2 = NO, OnAccept = function() local id = StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_ITEM].item_id if (id) then MiDKP_Core.Item.DeleteItem("@"..id) if (MiDKPItemPage:IsShown()) then MiDKP_UIHelp.Item.DoUpdate() end end end, OnCancel = function() end, OnShow = function() end, OnHide = function() MiDKP_UIHelp.Util.MainFrame_Enable(true) end, timeout = 0, hideOnEscape = 1, } MiDKP_Core={} MiDKP_Core.Util={ SendWhisperMessage=function(msg, player) local id = msg .. ":" .. player if (MiDKP_Options["hide_whisper_reply"]) then MiDKP_HiddenWhisper[id] = true MiDKP_AFKDND[player] = GetTime() end SendChatMessage(msg, "WHISPER", nil, player) end, DataGetMembers=function(MiDKP_f8c6f4951c524600d5984ab47a0d8393) if (MiDKPData and MiDKPData["dkp"]) then local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPData["dkp"]) do if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"] and MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"] == MiDKP_f8c6f4951c524600d5984ab47a0d8393) then return MiDKP_8d0644c92128c1ff68223fd74ba63b56["members"] end end end end, DataGetRaidByIndex=function(__index) if (MiDKPData and MiDKPData["dkp"] and MiDKPData["dkp"][__index]) then return MiDKPData["dkp"][__index]; end end, GetCount=function(MiDKP_e78d229014c7a07be65fde4797b92c86) if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "raid") then local index = 1 local MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = 0 if (MiDKP_Config["raids"]) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335 = 1, MiDKP_Core.Util.GetMaxID("raid"), 1 do if (MiDKP_Config["raids"][MiDKP_63a9ce6f1eeac72ef41293b7d0303335]) then MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_3f50417fb16be9b1078eb68d24fa9c26 + 1 end end end return MiDKP_3f50417fb16be9b1078eb68d24fa9c26 else local index = 1 local MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = 0 local raid = MiDKP_Core.Raid.GetCurrentRaid() if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "event") then if (raid["events"]) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335 = 1, MiDKP_Core.Util.GetMaxID(MiDKP_e78d229014c7a07be65fde4797b92c86), 1 do MiDKP_8d0644c92128c1ff68223fd74ba63b56 = raid["events"][MiDKP_63a9ce6f1eeac72ef41293b7d0303335] if (raid["events"][MiDKP_63a9ce6f1eeac72ef41293b7d0303335]) then MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_3f50417fb16be9b1078eb68d24fa9c26 + 1 end end end elseif (MiDKP_e78d229014c7a07be65fde4797b92c86 == "item") then if (raid["items"]) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335 = 1, MiDKP_Core.Util.GetMaxID(MiDKP_e78d229014c7a07be65fde4797b92c86), 1 do MiDKP_8d0644c92128c1ff68223fd74ba63b56 = raid["items"][MiDKP_63a9ce6f1eeac72ef41293b7d0303335] if (raid["items"][MiDKP_63a9ce6f1eeac72ef41293b7d0303335]) then MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_3f50417fb16be9b1078eb68d24fa9c26 + 1 end end end end return MiDKP_3f50417fb16be9b1078eb68d24fa9c26 end end, GetItemCount=function() return MiDKP_Core.Util.GetCount("item") end, GetRaidCount=function() return MiDKP_Core.Util.GetCount("raid") end, GetEventCount=function() return MiDKP_Core.Util.GetCount("event") end, GetMaxID=function(MiDKP_e78d229014c7a07be65fde4797b92c86) if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "raid") then if (not MiDKP_Config["raid_ids"]) then MiDKP_Config["raid_ids"] = 1 end return MiDKP_Config["raid_ids"] else local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end MiDKP_Core.Raid.InitIndex(raid) return raid["ids"][MiDKP_e78d229014c7a07be65fde4797b92c86] end end, GetID=function(MiDKP_e78d229014c7a07be65fde4797b92c86, index) if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "raid") then local id local i = 0 if (not MiDKP_Config["raid_ids"]) then MiDKP_Config["raid_ids"] = 1 end if (type(index) ~= "number") then if (type(index) == "string" and string.sub(index, 1, 1) == "@") then return tonumber(string.sub(index, 2, -1)) end index = tonumber(index) end if (not index) then return end for id = MiDKP_Config["raid_ids"] - 1, 1, -1 do if (MiDKP_Config["raids"][id]) then i = i + 1 end if (i == index) then return id end end else local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end MiDKP_Core.Raid.InitIndex(raid) if (type(index) ~= "number") then if (type(index) == "string" and string.sub(index, 1, 1) == "@") then return tonumber(string.sub(index, 2, -1)) end index = tonumber(index) end if (not index) then return end local id local i = 0 if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "event") then for id = raid["ids"]["event"] - 1, 1, -1 do if (raid["events"][id]) then i = i + 1 end if (i == index) then return id end end elseif (MiDKP_e78d229014c7a07be65fde4797b92c86 == "item") then for id = raid["ids"]["item"] - 1, 1, -1 do if (raid["items"][id]) then i = i + 1 end if (i == index) then return id end end end end end, GenerateID=function(MiDKP_e78d229014c7a07be65fde4797b92c86) if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "raid") then if (not MiDKP_Config["raid_ids"]) then MiDKP_Config["raid_ids"] = 1 end index = MiDKP_Config["raid_ids"] MiDKP_Config["raid_ids"] = MiDKP_Config["raid_ids"] + 1 return index else local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end MiDKP_Core.Raid.InitIndex(raid) local index if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "event") then index = raid["ids"]["event"] raid["ids"]["event"] = raid["ids"]["event"] + 1 elseif (MiDKP_e78d229014c7a07be65fde4797b92c86 == "item") then index = raid["ids"]["item"] raid["ids"]["item"] = raid["ids"]["item"] + 1 end return index end end, GetEventsByPage=function(raid,page) local MiDKP_e0744a0bff1e34800f14ca9a06b32530={} for MiDKP_63a9ce6f1eeac72ef41293b7d0303335 = 1, MIDKP_EVENT_PAGE_COUNT, 1 do local id = MiDKP_Core.Util.GetID("event", (page-1)*MIDKP_EVENT_PAGE_COUNT + MiDKP_63a9ce6f1eeac72ef41293b7d0303335); if (id) then MiDKP_8d0644c92128c1ff68223fd74ba63b56 = raid["events"][id]; MiDKP_e0744a0bff1e34800f14ca9a06b32530[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]={} MiDKP_e0744a0bff1e34800f14ca9a06b32530[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Name=MiDKP_8d0644c92128c1ff68223fd74ba63b56["desc"] MiDKP_e0744a0bff1e34800f14ca9a06b32530[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Tip=string.format(MIDKP_TEXT_EVENT_HAPPENS, MiDKP_8d0644c92128c1ff68223fd74ba63b56["time"][1]) if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"] and MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"] ~= 0) then MiDKP_e0744a0bff1e34800f14ca9a06b32530[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Bonus=string.format(MIDKP_TEXT_POINTS, MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"]); else MiDKP_e0744a0bff1e34800f14ca9a06b32530[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Bonus=""; end if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"]) then MiDKP_e0744a0bff1e34800f14ca9a06b32530[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].MemberCount=string.format(MIDKP_TEXT_RAID_TOTAL_MEMBER, table.maxn(MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"])); else MiDKP_e0744a0bff1e34800f14ca9a06b32530[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].MemberCount="" end end end return MiDKP_e0744a0bff1e34800f14ca9a06b32530 end, RegisterMod=function(ui_element) local MiDKP_650dc4675bce3b530ba350f731be8b52=function() SlashCmdList["MiDKP"] = MiDKP_Event.SlashCommandHandler MiDKP_Util:Print("info",MIDKP_INFO_GREETING) MiDKP_Old_ChatFrame_MessageEventHandler=ChatFrame_MessageEventHandler ChatFrame_MessageEventHandler=MiDKP_Event.ChatFrameMessageEventHandler MiDKP_Old_SetItemRef=SetItemRef SetItemRef=MiDKP_UIHelp.Util.SetItemRef MiDKP_Old_ChatEdit_InsertLink=ChatEdit_InsertLink ChatEdit_InsertLink=MiDKP_UIHelp.Util.ChatEdit_InsertLink MiDKPMiniButton:Show() ui_element:RegisterEvent("CHAT_MSG_LOOT") ui_element:RegisterEvent("ZONE_CHANGED_NEW_AREA") ui_element:RegisterEvent("RAID_ROSTER_UPDATE") ui_element:RegisterEvent("COMBAT_LOG_EVENT_UNFILTERED") ui_element:RegisterEvent("CHAT_MSG_MONSTER_YELL") ui_element:RegisterEvent("CHAT_MSG_MONSTER_EMOTE") ui_element:RegisterEvent("LOOT_OPENED") ui_element:RegisterEvent("CHAT_MSG_WHISPER") ui_element:RegisterEvent("PLAYER_REGEN_ENABLED") ui_element:RegisterEvent("PLAYER_REGEN_DISABLED") end local MiDKP_a00d003724d0ab9992199d167544cf9f=function() SlashCmdList["MiDKP"] = nil ChatFrame_MessageEventHandler=MiDKP_Old_ChatFrame_MessageEventHandler or ChatFrame_MessageEventHandler SetItemRef=MiDKP_Old_SetItemRef or SetItemRef ChatEdit_InsertLink=MiDKP_Old_ChatEdit_InsertLink or ChatEdit_InsertLink MiDKPMiniButton:Hide() ui_element:UnregisterEvent("CHAT_MSG_LOOT") ui_element:UnregisterEvent("ZONE_CHANGED_NEW_AREA") ui_element:UnregisterEvent("RAID_ROSTER_UPDATE") ui_element:UnregisterEvent("COMBAT_LOG_EVENT_UNFILTERED") ui_element:UnregisterEvent("CHAT_MSG_MONSTER_YELL") ui_element:UnregisterEvent("CHAT_MSG_MONSTER_EMOTE") ui_element:UnregisterEvent("LOOT_OPENED") ui_element:UnregisterEvent("CHAT_MSG_WHISPER") ui_element:UnregisterEvent("PLAYER_REGEN_ENABLED") ui_element:UnregisterEvent("PLAYER_REGEN_DISABLED") end if not (ModManagement_RegisterMod) then MiDKP_650dc4675bce3b530ba350f731be8b52() return end ModManagement_RegisterMod( "MiDKP", "Interface\\Icons\\INV_Misc_Toy_05", MIDKP_ADDON_TITLE, "", nil, nil, {[4]=true} ); ModManagement_RegisterCheckBox( "MiDKP", MIDKP_ADDON_ENABLE, nil, "MiDKPEnable", 0, function (arg) if (arg == 1 and not MiDKP_e60e25d6b953188ad3c52f917a45f7b8) then MiDKP_e60e25d6b953188ad3c52f917a45f7b8 = 1; if (not MiDKP_6581b65a15732c47fbd26c267d2abd87) then MiDKP_650dc4675bce3b530ba350f731be8b52() MiDKP_6581b65a15732c47fbd26c267d2abd87 = true; end elseif (arg == 0 and MiDKP_e60e25d6b953188ad3c52f917a45f7b8) then MiDKP_a00d003724d0ab9992199d167544cf9f(); MiDKP_6581b65a15732c47fbd26c267d2abd87=false; MiDKP_e60e25d6b953188ad3c52f917a45f7b8 = nil; end end ); end } MiDKP_Core.Raid={ GetCurrentRaidSize=function() local MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af = MiDKP_Core.Raid.GetCurrentRaid() local MiDKP_3f50417fb16be9b1078eb68d24fa9c26=0 if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af and MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"]) then return MiDKP_Util:Size(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"]) end return 0 end, DeleteRaid=function(index) local id = MiDKP_Core.Util.GetID("raid", index) if (not id) then MiDKP_Util:Print("error", MIDKP_TEXT_NO_SPEC_RAID) return end local name = MiDKP_Config["raids"][id]["name"] if (MiDKP_Config["raids"] and MiDKP_Config["raids"][id]) then MiDKP_Config["raids"][id] = nil end if (MiDKP_Config_Wrapper:IsIdMatchCurrent(id)) then MiDKP_Config["current_raid"] = nil end return true end, ActiveRaid=function(index) local id = MiDKP_Core.Util.GetID("raid", index) if (not id) or (not MiDKP_Config["raids"][id]) then MiDKP_Util:Print("error", MIDKP_TEXT_INVALID_RAID) return false end if (not MiDKP_Config["raids"][id]["start"]) then MiDKP_Util:Print("error", MIDKP_TEXT_RAID_NO_START) return false end MiDKP_Config["current_raid"] = id return true end, StartRaid=function(__index) if (GetNumRaidMembers() <= 0) then MiDKP_Util:Print("error", MIDKP_TEXT_NO_IN_RAID) return false end local raid,MiDKP_8d0febf2348ea712b2b375ae95601d5f if (not __index) then raid = MiDKP_Core.Raid.GetCurrentRaid() else MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Util.GetID("raid", __index) raid = MiDKP_Config["raids"][MiDKP_8d0febf2348ea712b2b375ae95601d5f] end if (raid and raid["start"]) then MiDKP_Util:Print("error", MIDKP_TEXT_RAID_ALREADY_START, raid["name"]) return false end if (MiDKP_Config["raids"]) then local k, v for k, v in pairs(MiDKP_Config["raids"]) do if (v["start"] and not v["end"]) then MiDKP_Util:Print("error", MIDKP_TEXT_ALREADY_HAS_RAID) return false end end end MiDKP_Config["current_raid"]=MiDKP_8d0febf2348ea712b2b375ae95601d5f raid["start"] = {} raid["start"]["time"] = MiDKP_Util:GetTimeStamp() raid["start"]["members"] = MiDKP_Util:GetRaidMemberSnapshot() raid["snapshot"]=raid["start"]["members"] MiDKP_Core.Member.UpdateMembers() MiDKP_Core.Member.SetMembersStartTime() MiDKP_Config["running_raid"] = MiDKP_Config["current_raid"] MiDKP_Util:Print("info", MIDKP_TEXT_RAID_STARTED_AND_ACTIVATED,raid["name"]) return true end, EndRaid=function(__index) local raid if (not __index) then raid = MiDKP_Core.Raid.GetCurrentRaid() else local id = MiDKP_Core.Util.GetID("raid", __index) raid = MiDKP_Config["raids"][id] end if (raid) then if (raid["end"]) then MiDKP_Util:Print("error", MIDKP_TEXT_RAID_ALREADY_END, raid["name"]) return false end raid["end"] = {} raid["end"]["time"] = MiDKP_Util:GetTimeStamp() raid["end"]["members"] = MiDKP_Util:GetRaidMemberSnapshot() MiDKP_Core.Member.SetMembersEndTime() MiDKP_Core.Member.ResetMembersStatus() MiDKP_Config["running_raid"] = nil MiDKP_Config["current_raid"] = nil end end, AddRaidPlace=function(place) local rname = MiDKP_Config["current_raid"] if (not MiDKP_Config["raids"][rname]["places"]) then MiDKP_Config["raids"][rname]["places"] = {} end local i, p for i, p in ipairs(MiDKP_Config["raids"][rname]["places"]) do if (place == p) then return end end table.insert(MiDKP_Config["raids"][rname]["places"], place) end, IsRaidValid=function() local rname = MiDKP_Config["current_raid"] if (not rname) then return false end if (MiDKP_Config["raids"][rname] and MiDKP_Config["raids"][rname]["start"] and not MiDKP_Config["raids"][rname]["end"]) then return true end return false end, Announce=function(channel, event, item,member) channel=nil local raid = MiDKP_Core.Raid.GetCurrentRaid() if (raid and raid["start"]) then local period if (raid["end"] and raid["end"]["time"]) then period = raid["end"]["time"][2] - raid["start"]["time"][2] else local t = MiDKP_Util:GetTimeStamp() period = t[2] - raid["start"]["time"][2] end SendChatMessage(string.format(MIDKP_TEXT_ANNOUNCE_1, raid["name"], MiDKP_Util:GetTimeString(period)), channel) if (event) then local event_index = 1 if (raid["events"]) then local k, v for k, v in pairs(raid["events"]) do if (event_index == 1) then SendChatMessage(string.format(MIDKP_TEXT_ANNOUNCE_2),channel) end if (not v["point"]) then v["point"] = 0 end SendChatMessage(string.format(MIDKP_TEXT_ANNOUNCE_4, event_index, v["desc"], v["point"]), channel) event_index = event_index + 1 end end end if (item) then local item_index = 1 if (raid["items"]) then local k, v for k, v in pairs(raid["items"]) do if (item_index == 1) then SendChatMessage(string.format(MIDKP_TEXT_ANNOUNCE_3), channel) end local player = MIDKP_TEXT_ANNOUNCE_6 if (v["players"] and v["players"][1]) then player = v["players"][1] end if (not v["point"]) then v["point"] = 0 end SendChatMessage(string.format(MIDKP_TEXT_ANNOUNCE_5, item_index, v["item"], player, v["point"]), channel) item_index = item_index + 1 end end end end if (member) then if(not MiDKPDKPPage.data)then return end if MiDKPDKPPage.showtype==0 then if (raid and raid["members"]) then local member_index = 1 local MiDKP_8d66b86b985300b0b02587d40ca441ad = MiDKP_Core.Util.DataGetMembers(raid["dkp"]) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs (MiDKPDKPPage.data) do if (member_index == 1) then SendChatMessage(MIDKP_TEXT_ANNOUNCE_7,channel) end if (not raid["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56.name]["point"]) then raid["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56.name]["point"] = 0 end local MiDKP_6122bf43eee70ccf290f0ed85a93f587; if MiDKP_8d66b86b985300b0b02587d40ca441ad then MiDKP_6122bf43eee70ccf290f0ed85a93f587= MiDKP_Util:GetElementPoint(MiDKP_8d66b86b985300b0b02587d40ca441ad[MiDKP_8d0644c92128c1ff68223fd74ba63b56.name]) end if (MiDKP_8d66b86b985300b0b02587d40ca441ad and MiDKP_8d66b86b985300b0b02587d40ca441ad[MiDKP_8d0644c92128c1ff68223fd74ba63b56.name]) then SendChatMessage(string.format(MIDKP_TEXT_ANNOUNCE_8, member_index, MiDKP_8d0644c92128c1ff68223fd74ba63b56.name, MiDKP_6122bf43eee70ccf290f0ed85a93f587, MiDKP_6122bf43eee70ccf290f0ed85a93f587 + raid["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56.name]["point"]),channel) else SendChatMessage(string.format(MIDKP_TEXT_ANNOUNCE_9, member_index, MiDKP_8d0644c92128c1ff68223fd74ba63b56.name, raid["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56.name]["point"]), channel) end member_index = member_index + 1 end if not raid["dkp"] then SendChatMessage(MIDKP_TEXT_RAID_NOT_BIND,channel) end end else local member_index = 1 for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs( MiDKPDKPPage.data) do if (member_index == 1) then SendChatMessage(string.format(MIDKP_TEXT_ANNOUNCE_10,MiDKP_Core.Util.DataGetRaidByIndex(MiDKPDKPPage.showtype).name),channel) end SendChatMessage(string.format(MIDKP_TEXT_ANNOUNCE_9, member_index, MiDKP_8d0644c92128c1ff68223fd74ba63b56.name, MiDKP_8d0644c92128c1ff68223fd74ba63b56.dkp), channel) member_index = member_index + 1 end end end end, GetRunningRaid=function() local id = MiDKP_Config["running_raid"] if (not id) then return end return MiDKP_Config["raids"][id] end, GetCurrentRaid=function() local rname = MiDKP_Config["current_raid"] if (not rname) then return end return MiDKP_Config["raids"][rname] end, CreateRaid=function(name, MiDKP_f8c6f4951c524600d5984ab47a0d8393) if (not name) then local time = MiDKP_Util:GetTimeStamp() name = MIDKP_TEXT_RAID_PATTERN .. time[1] .. ")" end if (not MiDKP_Config["raids"]) then MiDKP_Config["raids"] = {} end local id = MiDKP_Core.Util.GenerateID("raid") MiDKP_Config["raids"][id] = {} MiDKP_Config["raids"][id]["name"] = name MiDKP_Config["raids"][id]["dkp"] = MiDKP_f8c6f4951c524600d5984ab47a0d8393 MiDKP_Config["raids"][id]["creator"] = UnitName("player") MiDKP_Config["raids"][id]["ctime"] = MiDKP_Util:GetTimeStamp() MiDKP_Util:Print("info", MIDKP_INFO_CREATE_RAID, name) return id end, ModifyRaid=function(index, name, MiDKP_f8c6f4951c524600d5984ab47a0d8393) local id = MiDKP_Core.Util.GetID("raid", index) if (not id) then MiDKP_Util:Print("error", MIDKP_TEXT_NO_SPEC_RAID) return end if (MiDKP_Config["raids"][id]) then MiDKP_Config["raids"][id]["name"] = name MiDKP_Config["raids"][id]["dkp"] = MiDKP_f8c6f4951c524600d5984ab47a0d8393 end end, ExportRaid=function(index) local id = MiDKP_Core.Util.GetID("raid", index) local raid = MiDKP_Config["raids"][id] local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 local k2, v2 local xml = "" if (not id) then MiDKP_Util:Print("error", MIDKP_TEXT_NO_SPEC_RAID) return end xml = xml .. "<midkp>" xml = xml .. "<raid>" xml = xml .. "<name>" .. MiDKP_Util:ParseRealText(raid["name"]) .. "</name>" xml = xml .. "<version>" .. "0.90" .. "</version>" xml = xml .. "<start>" .. raid["start"]["time"][1] .. "</start>" xml = xml .. "<end>" .. raid["end"]["time"][1] .. "</end>" xml = xml .. "<creator>" .. raid["creator"] .. "</creator>" if (raid["places"]) then xml = xml .. "<places>" for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(raid["places"]) do xml = xml .. "<place>" .. MiDKP_8d0644c92128c1ff68223fd74ba63b56 .. "</place>" end xml = xml .. "</places>" end xml = xml .. "<members>" if (raid["members"]) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["members"]) do xml = xml .. "<member>" xml = xml .. "<name>" .. MiDKP_63a9ce6f1eeac72ef41293b7d0303335 .. "</name>" xml = xml .. "<class>" .. (MiDKP_8d0644c92128c1ff68223fd74ba63b56["class"] or "").. "</class>" xml = xml .. "</member>" end end xml = xml .. "</members>" xml = xml .. "<events>" if (raid["events"]) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["events"]) do xml = xml .. "<event>" xml = xml .. "<name>" .. MiDKP_Util:ParseRealText(MiDKP_8d0644c92128c1ff68223fd74ba63b56["desc"]) .. "</name>" if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["boss"]) then xml = xml .. "<boss>" .. MiDKP_8d0644c92128c1ff68223fd74ba63b56["boss"] .. "</boss>" end xml = xml .. "<time>" .. MiDKP_8d0644c92128c1ff68223fd74ba63b56["time"][1] .. "</time>" if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"]) then xml = xml .. "<members>" for k2, v2 in pairs(MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"]) do xml = xml .. "<member>" .. v2 .. "</member>" end xml = xml .. "</members>" end if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"]) then xml = xml .. "<point>" .. abs(MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"]) .. "</point>" if MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"]<0 then xml = xml .. "<punish>true</punish>" end end xml = xml .. "</event>" end else xml = xml .. "<event/>" end xml = xml .. "</events>" xml = xml .. "<items>" if (raid["items"]) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["items"]) do xml = xml .. "<item>" xml = xml .. "<name>" .. MiDKP_Util:ParseRealText(MiDKP_8d0644c92128c1ff68223fd74ba63b56["item"]) .. "</name>" xml = xml .. "<time>" .. MiDKP_8d0644c92128c1ff68223fd74ba63b56["time"][1] .. "</time>" if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"] and MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"][1]) then xml = xml .. "<looter>" .. MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"][1] .. "</looter>" end if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"]) then xml = xml .. "<point>" .. MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"] .. "</point>" end xml = xml .. "</item>" end else xml = xml .. "<item/>" end xml = xml .. "</items>" xml = xml .. "</raid>" xml = xml .. "</midkp>" return xml end, CreateEvent=function(desc, point, players, boss,MiDKP_fa7307fe0773c5bc7c9b34cafd8d8a1d,MiDKP_2e00ffac12aadb3a1fd865993ec505b9) local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end if (not raid["events"]) then raid["events"] = {} end if (not desc or string.len(desc) == 0) then MiDKP_Util:Print("error", MIDKP_TEXT_INVALID_EVENT) return end if (not point) then point = 0 end point = MiDKP_Util:GetPoint(point) if (not point) then return end if (not MiDKP_Core.Member.IsPlayersValid(players)) then MiDKP_Util:Print("error", MIDKP_TEXT_INVALID_PLAYER) return end local id = MiDKP_Core.Util.GenerateID("event") raid["events"][id] = {} raid["events"][id]["desc"] = desc raid["events"][id]["boss"] = boss raid["events"][id]["auto"] = MiDKP_fa7307fe0773c5bc7c9b34cafd8d8a1d raid["events"][id]["item"] = MiDKP_2e00ffac12aadb3a1fd865993ec505b9 raid["events"][id]["point"] = point raid["events"][id]["players"] = players raid["events"][id]["time"] = MiDKP_Util:GetTimeStamp() if (point and point ~= 0) then MiDKP_Core.Member.AddMemberPoint(players, point) end if (point == 0) then MiDKP_Util:Print("info", MIDKP_INFO_EVENT_ADD, desc, raid["events"][id]["time"][1]) else MiDKP_Util:Print("info", MIDKP_INFO_EVENT_POINT_ADD, desc, raid["events"][id]["time"][1], point) end return id end, DeleteEvent=function(index) local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end local id = MiDKP_Core.Util.GetID("event", index) if (not id) then MiDKP_Util:Print("error", MIDKP_TEXT_NO_EVENT) return end if not raid["events"][id] then return end if raid["events"][id]["item"] then raid ["items"][raid["events"][id]["item"]]["event"]=nil end local desc = raid["events"][id]["desc"] MiDKP_Core.Member.AddMemberPoint(raid["events"][id]["players"], -raid["events"][id]["point"]) raid["events"][id] = nil local index=1 while _G["MiDKPNotifyEventButton"..index] do local button= _G["MiDKPNotifyEventButton"..index] if button.id==id and button.category=="event" then button:Hide() end index = index + 1; end end, ModifyEvent=function(index, desc, point, players,boss,MiDKP_fa7307fe0773c5bc7c9b34cafd8d8a1d) local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end local id = MiDKP_Core.Util.GetID("event", index) or index if (not id) then MiDKP_Util:Print("error", MIDKP_TEXT_NO_EVENT) return end if (desc and string.len(desc) == 0) then MiDKP_Util:Print("error", MIDKP_TEXT_INVALID_EVENT) return end if (not point) then point = raid["events"][id]["point"] if (not point) then point = 0 end else point = MiDKP_Util:GetPoint(point) if (not point) then return end end if (players and not MiDKP_Core.Member.IsPlayersValid(players)) then MiDKP_Util:Print("error", MIDKP_TEXT_INVALID_PLAYER) return end if (not players) then players = raid["events"][id]["players"] end MiDKP_Core.Member.AddMemberPoint(raid["events"][id]["players"], -raid["events"][id]["point"]) if (players) then MiDKP_Core.Member.AddMemberPoint(players, point) else MiDKP_Core.Member.AddMemberPoint(raid["events"][id]["players"], point) end local old_desc = raid["events"][id]["desc"] if (desc) then raid["events"][id]["desc"] = desc end if (players) then raid["events"][id]["players"] = players end raid["events"][id]["point"] = point raid["events"][id]["boss"] = boss raid["events"][id]["auto"] = MiDKP_fa7307fe0773c5bc7c9b34cafd8d8a1d MiDKP_Util:Print("info", MIDKP_INFO_EVENT_MODIFIED, old_desc) return true end, IsRaidRunning=function() local raid = MiDKP_Core.Raid.GetCurrentRaid() if (raid and raid["start"] and not raid["end"]) then return true end end, InitIndex=function(raid) if (not raid["ids"]) then raid["ids"] = {} raid["ids"]["item"] = 1 raid["ids"]["event"] = 1 raid["ids"]["raid"] = 1 end end, GetSuites=function() return MiDKP_Options["suites"] or {true,true,true,true,true,true,true,true,true,true,true,true,true} end, SetSuites=function(MiDKP_02c80878ad0182c72ee6a6a3a60d04b7) MiDKP_Options["suites"]=MiDKP_02c80878ad0182c72ee6a6a3a60d04b7 or {} end } MiDKP_Core.Member={ DeleteMember=function(name) local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid["members"] or not raid["members"][name]) then MiDKP_Util:Print("error", MIDKP_TEXT_NO_MEMBER, name) return end raid["members"][name] = nil if (not raid["events"]) then return end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["events"])do for MiDKP_b346ff9c8a9ef882088b9f1c82dabf17,MiDKP_1f767451a35d2d22ad352ee7ff068312 in pairs(MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"])do if MiDKP_1f767451a35d2d22ad352ee7ff068312==name then table.remove(MiDKP_8d0644c92128c1ff68223fd74ba63b56,MiDKP_b346ff9c8a9ef882088b9f1c82dabf17) end end end end, AddMember=function(MiDKP_8983c60d66c8593ec7165ea9dbedb584,MiDKP_b962f54280c77029bc350c2b321adc64) local raid = MiDKP_Core.Raid.GetCurrentRaid() if ((not raid) or (not raid["members"] )) then if GetNumRaidMembers()>0 then MiDKP_Util:Print("error", MIDKP_TEXT_NO_SPEC_RAID) else MiDKP_Util:Print("error", MIDKP_TEXT_NO_IN_RAID) end return false end if ( raid["members"][MiDKP_8983c60d66c8593ec7165ea9dbedb584]) then MiDKP_Util:Print("error", MIDKP_TEXT_MEMBER_INLIST, MiDKP_8983c60d66c8593ec7165ea9dbedb584) return false end if not MiDKP_Util:IsValidName(MiDKP_8983c60d66c8593ec7165ea9dbedb584)then MiDKP_Util:Print("error", MIDKP_TEXT_INVALID_PLAYER) return false end local MiDKP_f9542af0fc240db769f6a4369804f562=MiDKP_Core.Util.DataGetMembers(raid["dkp"]) if MiDKP_f9542af0fc240db769f6a4369804f562 and MiDKP_f9542af0fc240db769f6a4369804f562[MiDKP_8983c60d66c8593ec7165ea9dbedb584] then if type(MiDKP_f9542af0fc240db769f6a4369804f562[MiDKP_8983c60d66c8593ec7165ea9dbedb584])=='table' and MiDKP_f9542af0fc240db769f6a4369804f562[MiDKP_8983c60d66c8593ec7165ea9dbedb584]["class"] and string.upper(MiDKP_f9542af0fc240db769f6a4369804f562[MiDKP_8983c60d66c8593ec7165ea9dbedb584]["class"])~=string.upper(MiDKP_b962f54280c77029bc350c2b321adc64:upper()) and string.upper(MiDKP_f9542af0fc240db769f6a4369804f562[MiDKP_8983c60d66c8593ec7165ea9dbedb584]["class"])~="UNKNOWN" then MiDKP_Util:Print("error", MIDKP_TEXT_CLASS_NOT_MATCH) return false,MiDKP_f9542af0fc240db769f6a4369804f562[MiDKP_8983c60d66c8593ec7165ea9dbedb584]["class"] end end raid["members"][MiDKP_8983c60d66c8593ec7165ea9dbedb584] = {} if(MiDKP_b962f54280c77029bc350c2b321adc64 and MIDKP_CLASS[string.upper(MiDKP_b962f54280c77029bc350c2b321adc64)]) then raid["members"][MiDKP_8983c60d66c8593ec7165ea9dbedb584]["class"]=MiDKP_b962f54280c77029bc350c2b321adc64 raid["members"][MiDKP_8983c60d66c8593ec7165ea9dbedb584]["lclass"]=MIDKP_CLASS[string.upper(MiDKP_b962f54280c77029bc350c2b321adc64)].text1 end raid["members"][MiDKP_8983c60d66c8593ec7165ea9dbedb584]["point"]=0 raid["members"][MiDKP_8983c60d66c8593ec7165ea9dbedb584]["inraid"]=0 raid["members"][MiDKP_8983c60d66c8593ec7165ea9dbedb584]["online"] = 0 raid["members"][MiDKP_8983c60d66c8593ec7165ea9dbedb584]["group"] = nil return true end, ResetMembersStatus=function() local raid=MiDKP_Core.Raid.GetCurrentRaid() if((not raid) or (not raid.members)) then return end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid.members) do MiDKP_8d0644c92128c1ff68223fd74ba63b56["inraid"]=0 MiDKP_8d0644c92128c1ff68223fd74ba63b56["online"]=nil MiDKP_8d0644c92128c1ff68223fd74ba63b56["group"]=nil end end, AddMemberNote=function(name, point, reason) local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end if (not raid["members"] or not raid["members"][name]) then MiDKP_Util:Print("error", MIDKP_TEXT_NO_MEMBER, name) return end if (not raid["members"][name]["notes"]) then raid["members"][name]["notes"] = {} end point = MiDKP_Util:GetPoint(point) if (not point) then return end if (not reason) then reason = "" end local data = {point, reason, MiDKP_Util:GetTimeStamp()} table.insert(raid["members"][name]["notes"], data) MiDKP_Core.Member.AddMemberPoint(name, point) end, UpdateMembers=function() local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end local num = GetNumRaidMembers() local current_members = {} if (num > 0) then local index for index = 1, num, 1 do local unit = "raid"..index local name, rank, subgroup, level, class, fileName, zone, online, isDead, role, isML = GetRaidRosterInfo(index) if (name and name ~= UNKNOWNBEING and name ~= UNKNOWN and MiDKP_Util:IsValidName(name) )then if (not raid["members"]) then raid["members"] = {} end if (raid["members"][name]) then if (raid["members"][name]["inraid"] ~= 1) then if (not raid["members"][name]["join"]) then raid["members"][name]["join"] = {} end table.insert(raid["members"][name]["join"], MiDKP_Util:GetTimeStamp()) end else raid["members"][name] = {} raid["members"][name]["join"] = MiDKP_Util:GetTimeStamp() end raid["members"][name]["inraid"] = 1 if (online) then raid["members"][name]["online"] = 1 else raid["members"][name]["online"] = 0 end raid["members"][name]["group"] = subgroup raid["members"][name]["class"] = fileName raid["members"][name]["lclass"] = class if not raid["members"][name]["point"] then raid["members"][name]["point"]=0 end current_members[name] = true end end end if (raid["members"]) then local name, data for name, data in pairs(raid["members"]) do if (not current_members[name]) then data["online"] = nil data["inraid"] = 0 data["group"] = nil end end end end, IsPlayersValid=function(players) local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end if (not raid["members"]) then return end local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(players) do if (not raid["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56]) then return end end return true end, AddMemberPoint=function(name,point) local rname = MiDKP_Config["current_raid"] if (not rname) then return end if (not MiDKP_Config["raids"][rname]) then return end if (not MiDKP_Config["raids"][rname]["members"]) then return end local i, MiDKP_8d0644c92128c1ff68223fd74ba63b56 if (name) then if (type(name) == "table") then for i, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(name) do if (MiDKP_Config["raids"][rname]["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56]) then if (not MiDKP_Config["raids"][rname]["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56]["point"]) then MiDKP_Config["raids"][rname]["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56]["point"] = 0 end MiDKP_Config["raids"][rname]["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56]["point"] = MiDKP_Config["raids"][rname]["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56]["point"] + point end end elseif (type(name) == "string") then if (MiDKP_Config["raids"][rname]["members"][name]) then if (not MiDKP_Config["raids"][rname]["members"][name]["point"]) then MiDKP_Config["raids"][rname]["members"][name]["point"] = 0 end MiDKP_Config["raids"][rname]["members"][name]["point"] = MiDKP_Config["raids"][rname]["members"][name]["point"] + point end end end end, GetMembersArray=function(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3, disconnected) local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end local members = {} local temp = {} local ret = {} local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 if (MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3 == "first5") then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["members"]) do if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["group"] and MiDKP_8d0644c92128c1ff68223fd74ba63b56["group"] <= 5) then members[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] = true end end elseif (MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3 == "all") then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["members"]) do members[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] = true end elseif (MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3 == "raid") then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["members"]) do if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["inraid"]==1) then members[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] = true end end elseif (MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3 == "none") then end if MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3~="all" and (not disconnected) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(members) do if (raid["members"][MiDKP_63a9ce6f1eeac72ef41293b7d0303335]["online"] == 1) then temp[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] = true end end members = temp end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(members) do table.insert(ret, MiDKP_63a9ce6f1eeac72ef41293b7d0303335) end return ret end, SetMembersEndTime=function() local raid=MiDKP_Core.Raid.GetCurrentRaid() if((not raid) or (not raid.members)) then return end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid.members) do MiDKP_8d0644c92128c1ff68223fd74ba63b56["endtime"]=MiDKP_Util:GetTimeStamp() end end, SetMembersStartTime=function() local raid=MiDKP_Core.Raid.GetCurrentRaid() if((not raid) or (not raid.members)) then return end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid.members) do MiDKP_8d0644c92128c1ff68223fd74ba63b56["starttime"]=MiDKP_Util:GetTimeStamp() end end, HasStartTime=function(MiDKP_1210e713fbe7372fde7a5518a1f280ec) local raid=MiDKP_Core.Raid.GetCurrentRaid() if((not raid) or (not raid.members)) then return false end if MiDKP_1210e713fbe7372fde7a5518a1f280ec and MiDKP_1210e713fbe7372fde7a5518a1f280ec.name and raid.members[MiDKP_1210e713fbe7372fde7a5518a1f280ec.name] then return raid.members[MiDKP_1210e713fbe7372fde7a5518a1f280ec.name].starttime end return false end, SetStartTime=function(MiDKP_1210e713fbe7372fde7a5518a1f280ec) local raid=MiDKP_Core.Raid.GetCurrentRaid() if((not raid) or (not raid.members)) then return false end if MiDKP_1210e713fbe7372fde7a5518a1f280ec and MiDKP_1210e713fbe7372fde7a5518a1f280ec.name and raid.members[MiDKP_1210e713fbe7372fde7a5518a1f280ec.name] then raid.members[MiDKP_1210e713fbe7372fde7a5518a1f280ec.name]["starttime"]=MiDKP_Util:GetTimeStamp() return true end return false end, SetEndTime=function(MiDKP_1210e713fbe7372fde7a5518a1f280ec) local raid=MiDKP_Core.Raid.GetCurrentRaid() if((not raid) or (not raid.members)) then return false end if MiDKP_1210e713fbe7372fde7a5518a1f280ec and MiDKP_1210e713fbe7372fde7a5518a1f280ec.name and raid.members[MiDKP_1210e713fbe7372fde7a5518a1f280ec.name] then raid.members[MiDKP_1210e713fbe7372fde7a5518a1f280ec.name]["endtime"]=MiDKP_Util:GetTimeStamp() return true end return false end, ClearEndTime=function(MiDKP_1210e713fbe7372fde7a5518a1f280ec) local raid=MiDKP_Core.Raid.GetCurrentRaid() if((not raid) or (not raid.members)) then return false end if not MiDKP_1210e713fbe7372fde7a5518a1f280ec.name then return false end if MiDKP_1210e713fbe7372fde7a5518a1f280ec and MiDKP_1210e713fbe7372fde7a5518a1f280ec.name and raid.members[MiDKP_1210e713fbe7372fde7a5518a1f280ec.name] then raid.members[MiDKP_1210e713fbe7372fde7a5518a1f280ec.name]["endtime"]=nil return true end return false end, GetClassText=function(MiDKP_1210e713fbe7372fde7a5518a1f280ec) local text="" if type(MiDKP_1210e713fbe7372fde7a5518a1f280ec)=="number" or type(MiDKP_1210e713fbe7372fde7a5518a1f280ec)=="string" then return text end if(MiDKP_1210e713fbe7372fde7a5518a1f280ec["class"] ) then if(MIDKP_CLASS[string.upper(MiDKP_1210e713fbe7372fde7a5518a1f280ec["class"])])then text =MiDKP_Util:RenderText(MIDKP_CLASS[string.upper(MiDKP_1210e713fbe7372fde7a5518a1f280ec["class"])].text1,MIDKP_CLASS[string.upper(MiDKP_1210e713fbe7372fde7a5518a1f280ec["class"])].color) end end return text end, GetTimeText=function(MiDKP_1210e713fbe7372fde7a5518a1f280ec) local text="" if(MiDKP_1210e713fbe7372fde7a5518a1f280ec.starttime) then text=MIDKP_TEXT_JOIN_TIME..MiDKP_1210e713fbe7372fde7a5518a1f280ec.starttime[1] end if(MiDKP_1210e713fbe7372fde7a5518a1f280ec.endtime) then text=text.." "..MIDKP_TEXT_LEAVE_TIME..MiDKP_1210e713fbe7372fde7a5518a1f280ec.endtime[1] end return text end, GetMembersByPage=function(filter,page,raid,MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3) local MiDKP_8d66b86b985300b0b02587d40ca441ad = MiDKP_Core.Util.DataGetMembers(raid["dkp"]) local MiDKP_da08ebd27a9615fb2152b9485cfde81d={} for MiDKP_63a9ce6f1eeac72ef41293b7d0303335 = 1, MIDKP_MEMBER_PAGE_COUNT, 1 do local __index = filter[(page-1)*MIDKP_MEMBER_PAGE_COUNT + MiDKP_63a9ce6f1eeac72ef41293b7d0303335] local name=__index and __index.name if (name) then MiDKP_8d0644c92128c1ff68223fd74ba63b56 = raid["members"][name] MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]={} MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Name=name MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Class=MiDKP_Core.Member.GetClassText(MiDKP_8d0644c92128c1ff68223fd74ba63b56) MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Tip=MiDKP_Core.Member.GetTimeText(MiDKP_8d0644c92128c1ff68223fd74ba63b56) local MiDKP_1df8102b35c02eafbc40642339a2c502,MiDKP_0793149f82d0d5b8930bd367071e02d1 if (MiDKP_8d66b86b985300b0b02587d40ca441ad and MiDKP_8d66b86b985300b0b02587d40ca441ad[name]) then local MiDKP_0001857ddc87bc382cff1ce608260a07; if(type(MiDKP_8d66b86b985300b0b02587d40ca441ad[name])=='number')then MiDKP_0001857ddc87bc382cff1ce608260a07=MiDKP_8d66b86b985300b0b02587d40ca441ad[name] else MiDKP_0001857ddc87bc382cff1ce608260a07=MiDKP_8d66b86b985300b0b02587d40ca441ad[name].score end MiDKP_1df8102b35c02eafbc40642339a2c502=MiDKP_0001857ddc87bc382cff1ce608260a07 + (MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"] or 0) else MiDKP_1df8102b35c02eafbc40642339a2c502=0 + (MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"] or 0) end MiDKP_0793149f82d0d5b8930bd367071e02d1=MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"] or 0 local bonusmemberString,bonusdkpString,totalBonusString,totalBonusdkpString bonusmemberString=string.format(MIDKP_TEXT_POINTS_SHORT,MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"] or 0) bonusdkpString=string.format(MIDKP_TEXT_POINTS,MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"] or 0) totalBonusString=string.format(MIDKP_TEXT_POINTS_SHORT, MiDKP_1df8102b35c02eafbc40642339a2c502) totalBonusdkpString=string.format(MIDKP_TEXT_TOTAL_POINTS, MiDKP_1df8102b35c02eafbc40642339a2c502) if MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3=="member" then MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Bonus=bonusmemberString MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].TotalBonus=totalBonusString elseif MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3=="dkp" then MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].TotalBonus=bonusdkpString MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Bonus=totalBonusdkpString end end end return MiDKP_da08ebd27a9615fb2152b9485cfde81d end, FilterSortMembers=function(MiDKP_e5e6de68d2a1aaafcf13014c54794791,MiDKP_18c26a4ea57e8b069341fcb3eca859ea,MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351,MiDKP_3b7e0d5210b1b5bed15b1f8591e78067,MiDKP_f8c6f4951c524600d5984ab47a0d8393) local members = {} local key=MiDKP_18c26a4ea57e8b069341fcb3eca859ea local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56; if not MiDKP_e5e6de68d2a1aaafcf13014c54794791 then return members end local dkplist={}; if MiDKP_f8c6f4951c524600d5984ab47a0d8393 then dkplist=MiDKP_Core.Util.DataGetMembers(MiDKP_f8c6f4951c524600d5984ab47a0d8393) or {} end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_e5e6de68d2a1aaafcf13014c54794791) do local MiDKP_fa2167574a7f10a8ceef1d978b1d1540={} local MiDKP_6038ab7974d0c47e254de7f62c6f404d =MiDKP_Util:GetElementPoint(MiDKP_8d0644c92128c1ff68223fd74ba63b56) or 0 local MiDKP_590b90ade4d8f094d6ded2e259e935a1=MiDKP_Util:GetElementClass(MiDKP_8d0644c92128c1ff68223fd74ba63b56) if dkplist[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] then MiDKP_fa2167574a7f10a8ceef1d978b1d1540.totaldkp=dkplist[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]["score"]+(MiDKP_6038ab7974d0c47e254de7f62c6f404d or 0) else MiDKP_fa2167574a7f10a8ceef1d978b1d1540.totaldkp=MiDKP_6038ab7974d0c47e254de7f62c6f404d end MiDKP_fa2167574a7f10a8ceef1d978b1d1540.name,MiDKP_fa2167574a7f10a8ceef1d978b1d1540.dkp=MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_6038ab7974d0c47e254de7f62c6f404d if((MiDKP_590b90ade4d8f094d6ded2e259e935a1 and MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351[string.upper(MiDKP_590b90ade4d8f094d6ded2e259e935a1)]) or MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351["All"])then MiDKP_fa2167574a7f10a8ceef1d978b1d1540.class=MiDKP_590b90ade4d8f094d6ded2e259e935a1 or "" table.insert(members, MiDKP_fa2167574a7f10a8ceef1d978b1d1540); end end table.sort(members,function(a,b) if( a[key] and b[key])then if (MiDKP_3b7e0d5210b1b5bed15b1f8591e78067[key]=="asc" )then return a[key] > b[key] else return a[key] < b[key] end else return false end end ); return members end, SendMemberPoint=function(player,point,total,MiDKP_a636447a4c34c16498e0f9d1b42ad9b1,MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3) local MiDKP_baa13c21288f98e62afb9d36f9f9c1f6, MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7 if total then MiDKP_baa13c21288f98e62afb9d36f9f9c1f6=select(3,string.find(total,"(-?%d+)")); end if point then MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7 = select(3,string.find(point,"(-?%d+)")); end if not MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3 then MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3="" end if MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7 and MiDKP_baa13c21288f98e62afb9d36f9f9c1f6 then SendChatMessage(string.format(MIDKP_TEXT_MEMBER_CURRENT_TOTAL_PLAYER,player,MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3,MiDKP_baa13c21288f98e62afb9d36f9f9c1f6-MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7,MiDKP_baa13c21288f98e62afb9d36f9f9c1f6), MiDKP_a636447a4c34c16498e0f9d1b42ad9b1) elseif MiDKP_baa13c21288f98e62afb9d36f9f9c1f6 then SendChatMessage(string.format(MIDKP_TEXT_MEMBER_INFO5_PLAYER,player,MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3,total), MiDKP_a636447a4c34c16498e0f9d1b42ad9b1) end end, } MiDKP_Core.Item={ GetNumIgnoreItems=function() return table.getn(MiDKP_Options["ignore_items"]) end, GetIgnoreItemInfo=function(index) return MiDKP_Options["ignore_items"][index] end, DeleteIgnoreItem=function(index) table.remove(MiDKP_Options["ignore_items"], index) MiDKP_Core.Item.BuildIgnoreItemsIndex() end, AddIgnoreItem=function(name) table.insert(MiDKP_Options["ignore_items"], name) MiDKP_Core.Item.BuildIgnoreItemsIndex() end, CreateItem=function(item, point, players,split_point) local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid["items"]) then raid["items"] = {} end if (not point) then point = 0 end point = MiDKP_Util:GetPoint(point) if (not point) then return end if (not MiDKP_Core.Member.IsPlayersValid(players)) then MiDKP_Util:Print("error", MIDKP_TEXT_INVALID_PLAYER) return end local id = MiDKP_Core.Util.GenerateID("item") raid["items"][id] = {} raid["items"][id]["item"] = item raid["items"][id]["point"] = point raid["items"][id]["players"] = players if split_point then local members = MiDKP_Core.Member.GetMembersArray(MiDKP_Options["default_member_filter"], MiDKP_Options["member_record_disconnected"]) local membersize= MiDKP_Util:Size(members) local average_gain=0 if membersize>0 then average_gain=string.twodigitfloat(point/ MiDKP_Util:Size(members)) end local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Raid.CreateEvent(string.format(MIDKP_TEXT_SPLIT_ITEM_POINTS, item), average_gain, members, false,false,id) raid["items"][id]["event"] = MiDKP_8d0febf2348ea712b2b375ae95601d5f else raid["items"][id]["event"] = nil end raid["items"][id]["time"] = MiDKP_Util:GetTimeStamp() if (point and point ~= 0) then MiDKP_Core.Member.AddMemberPoint(players, -point) end return id end, DeleteItem=function(index) local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid) then return end local id = MiDKP_Core.Util.GetID("item", index) if (not id) then MiDKP_Util:Print("error", MIDKP_TEXT_NO_ITEM) return end local old_name = raid["items"][id]["item"] MiDKP_Core.Member.AddMemberPoint(raid["items"][id]["players"], raid["items"][id]["point"]) if raid["items"][id]["event"] then local event_id=raid["items"][id]["event"] raid["items"][id]["event"]=nil raid["events"][event_id]["item"]=nil MiDKP_Core.Raid.DeleteEvent("@"..event_id) end raid["items"][id] = nil local index=1 while _G["MiDKPNotifyEventButton"..index] do local button= _G["MiDKPNotifyEventButton"..index] if button.id==id and button.category=="item" then button:Hide() end index = index + 1; end end, ModifyItem=function(index, item, point, players,split_points) local raid = MiDKP_Core.Raid.GetCurrentRaid() if (not raid["items"]) then raid["items"] = {} end local id = MiDKP_Core.Util.GetID("item", index) if (not id) then MiDKP_Util:Print("error", MIDKP_TEXT_NO_ITEM) return end if (not point) then point = raid["items"][id]["point"] if (not point) then point = 0 end else point = MiDKP_Util:GetPoint(point) if (not point) then return end end if (players and not MiDKP_Core.Member.IsPlayersValid(players)) then MiDKP_Util:Print("error", MIDKP_TEXT_INVALID_PLAYER) return end if (not players) then players = raid["items"][id]["players"] end local old_name = raid["items"][id]["item"] if (raid["items"][id]["point"] and raid["items"][id]["point"] ~= 0 and raid["items"][id]["players"]) then MiDKP_Core.Member.AddMemberPoint(raid["items"][id]["players"], raid["items"][id]["point"]) end if (item) then raid["items"][id]["item"] = item end if split_points then local MiDKP_8424088973cf3a8a961c883ddc6580ea=raid["items"][id]["event"] if MiDKP_8424088973cf3a8a961c883ddc6580ea then local membersize= MiDKP_Util:Size(raid["events"][MiDKP_8424088973cf3a8a961c883ddc6580ea]["players"]) local MiDKP_49069f122b324d5215277206ad993914=0 if membersize>0 then MiDKP_49069f122b324d5215277206ad993914=string.twodigitfloat(point/membersize) end MiDKP_Core.Raid.ModifyEvent(MiDKP_8424088973cf3a8a961c883ddc6580ea,nil,MiDKP_49069f122b324d5215277206ad993914,nil,nil,false) else local members = MiDKP_Core.Member.GetMembersArray(MiDKP_Options["default_member_filter"], MiDKP_Options["member_record_disconnected"]) local membersize= MiDKP_Util:Size(members) local average_gain=0 if membersize>0 then average_gain=string.twodigitfloat(point/ MiDKP_Util:Size(members)) end local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Raid.CreateEvent(string.format(MIDKP_TEXT_SPLIT_ITEM_POINTS, item), average_gain, members, false,false,id) raid["items"][id]["event"] = MiDKP_8d0febf2348ea712b2b375ae95601d5f end else if raid["items"][id]["event"] then raid["events"][raid["items"][id]["event"]]["item"]=nil MiDKP_Core.Raid.DeleteEvent("@"..raid["items"][id]["event"]) end raid["items"][id]["event"] = nil end raid["items"][id]["point"] = point if (players) then raid["items"][id]["players"] = players end MiDKP_Core.Member.AddMemberPoint(players, -point) return true end, BuildIgnoreItemsIndex=function() local k, v MiDKP_IgnoreItems = {} for k, v in ipairs(MiDKP_Options["ignore_items"]) do MiDKP_IgnoreItems[v] = true end end, GetItemLink=function(arg1) local MiDKP_9c987de176f2b454baede402cee36bfa,MiDKP_e498578b78aa0db9c45f30f87d63debc,MiDKP_3f50417fb16be9b1078eb68d24fa9c26 if (not MiDKP_e498578b78aa0db9c45f30f87d63debc) then MiDKP_9c987de176f2b454baede402cee36bfa, MiDKP_e498578b78aa0db9c45f30f87d63debc, MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_Util:FindString(arg1, MIDKP_LOOT_ITEM_MULTIPLE) end if (not MiDKP_e498578b78aa0db9c45f30f87d63debc) then MiDKP_9c987de176f2b454baede402cee36bfa, MiDKP_e498578b78aa0db9c45f30f87d63debc = MiDKP_Util:FindString(arg1, MIDKP_LOOT_ITEM) end if (not MiDKP_e498578b78aa0db9c45f30f87d63debc) then MiDKP_e498578b78aa0db9c45f30f87d63debc, MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_Util:FindString(arg1, MIDKP_LOOT_ITEM_SELF_MULTIPLE) end if (not MiDKP_e498578b78aa0db9c45f30f87d63debc) then MiDKP_e498578b78aa0db9c45f30f87d63debc = MiDKP_Util:FindString(arg1, MIDKP_LOOT_ITEM_SELF) end if (not MiDKP_e498578b78aa0db9c45f30f87d63debc) then MiDKP_e498578b78aa0db9c45f30f87d63debc = MiDKP_Util:FindString(arg1, MIDKP_LOOT_ITEM_PUSHED_SELF) end if (not MiDKP_e498578b78aa0db9c45f30f87d63debc) then MiDKP_e498578b78aa0db9c45f30f87d63debc,MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_Util:FindString(arg1, MIDKP_LOOT_ITEM_PUSHED_SELF_MULTIPLE) end if (not MiDKP_9c987de176f2b454baede402cee36bfa or MiDKP_9c987de176f2b454baede402cee36bfa == MIDKP_YOU_TEXT) then MiDKP_9c987de176f2b454baede402cee36bfa = UnitName("player") end if (not MiDKP_e498578b78aa0db9c45f30f87d63debc) then return end return MiDKP_9c987de176f2b454baede402cee36bfa,MiDKP_e498578b78aa0db9c45f30f87d63debc,MiDKP_3f50417fb16be9b1078eb68d24fa9c26 end, GetItemsByPage=function(raid,page) local MiDKP_63a9ce6f1eeac72ef41293b7d0303335 local MiDKP_8e6c2aaeb6b11f026ff5cb0a29aebe68={} for MiDKP_63a9ce6f1eeac72ef41293b7d0303335 = 1, MIDKP_ITEM_PAGE_COUNT, 1 do local id = MiDKP_Core.Util.GetID("item", (page-1)*MIDKP_ITEM_PAGE_COUNT + MiDKP_63a9ce6f1eeac72ef41293b7d0303335); if (id) then MiDKP_8d0644c92128c1ff68223fd74ba63b56 = raid["items"][id]; MiDKP_8e6c2aaeb6b11f026ff5cb0a29aebe68[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]={} MiDKP_8e6c2aaeb6b11f026ff5cb0a29aebe68[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Name=MiDKP_8d0644c92128c1ff68223fd74ba63b56["item"] MiDKP_8e6c2aaeb6b11f026ff5cb0a29aebe68[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Tip=string.format(MIDKP_TEXT_EVENT_HAPPENS, MiDKP_8d0644c92128c1ff68223fd74ba63b56["time"][1]) if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"] and MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"] ~= 0) then MiDKP_8e6c2aaeb6b11f026ff5cb0a29aebe68[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Bonus=string.format(MIDKP_TEXT_POINTS, MiDKP_8d0644c92128c1ff68223fd74ba63b56["point"]) else MiDKP_8e6c2aaeb6b11f026ff5cb0a29aebe68[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Bonus="" end if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"] and MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"][1]) then MiDKP_8e6c2aaeb6b11f026ff5cb0a29aebe68[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Looter=string.format(MIDKP_TEXT_ACCQUIRE, MiDKP_8d0644c92128c1ff68223fd74ba63b56["players"][1]); else MiDKP_8e6c2aaeb6b11f026ff5cb0a29aebe68[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Looter=""; end end end return MiDKP_8e6c2aaeb6b11f026ff5cb0a29aebe68 end, GetItemById=function(id) local raid = MiDKP_Core.Raid.GetCurrentRaid() if not raid then return end if not raid ["items"] then return end return raid["items"][id] end, } MiDKP_Core.DKP={ GetCurrentDataSize=function() return MiDKP_Core.Raid.GetCurrentRaidSize() end, GetDKPMembersByPage=function(filter,page,members) local MiDKP_da08ebd27a9615fb2152b9485cfde81d={} for MiDKP_63a9ce6f1eeac72ef41293b7d0303335 = 1, MIDKP_DKP_PAGE_COUNT, 1 do local __index = filter[(page-1)*MIDKP_DKP_PAGE_COUNT + MiDKP_63a9ce6f1eeac72ef41293b7d0303335] local name=__index and __index.name if (name) then local MiDKP_590b90ade4d8f094d6ded2e259e935a1=MiDKP_Util:GetElementClass(members[name]) local MiDKP_6038ab7974d0c47e254de7f62c6f404d=MiDKP_Util:GetElementPoint(members[name]) MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]={} MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Name=name MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Class=MiDKP_Core.Member.GetClassText(members[name]) MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Bonus=string.format(MIDKP_TEXT_TOTAL_POINTS_HIST, MiDKP_6038ab7974d0c47e254de7f62c6f404d ) MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].TotalBonus="" MiDKP_da08ebd27a9615fb2152b9485cfde81d[MiDKP_63a9ce6f1eeac72ef41293b7d0303335].Tip ="" end end return MiDKP_da08ebd27a9615fb2152b9485cfde81d end } MiDKP_Event={ ChatMsgLootHandler=function(...) if (not MiDKP_Core.Raid.IsRaidRunning()) then return end local arg1 = ... local raid=MiDKP_Core.Raid.GetRunningRaid() local player, MiDKP_e498578b78aa0db9c45f30f87d63debc, MiDKP_3f50417fb16be9b1078eb68d24fa9c26=MiDKP_Core.Item.GetItemLink(arg1) if (not MiDKP_e498578b78aa0db9c45f30f87d63debc) then return end local name, link, MiDKP_5fb35c5c169c804bc82bd7f93ad8e32f, iLevel, reqLevel, MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3, subType, maxStack, equipSlot, texture = GetItemInfo(MiDKP_e498578b78aa0db9c45f30f87d63debc) if (name and MiDKP_5fb35c5c169c804bc82bd7f93ad8e32f) then if (MiDKP_IgnoreItems[name]) then return end if (MiDKP_5fb35c5c169c804bc82bd7f93ad8e32f >= MiDKP_Options["min_quality"]) or MiDKP_Debug then if not raid["members"][player] then MiDKP_Util:Print("error", MIDKP_TEXT_NO_MEMBER,player) return end MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = tonumber(MiDKP_3f50417fb16be9b1078eb68d24fa9c26) if (not MiDKP_3f50417fb16be9b1078eb68d24fa9c26) then MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = 1 end if (MiDKP_3f50417fb16be9b1078eb68d24fa9c26 > 1) then MiDKP_142b84222c10ce51b520d7d7136fa08a=MiDKP_e498578b78aa0db9c45f30f87d63debc.."x"..MiDKP_3f50417fb16be9b1078eb68d24fa9c26 else MiDKP_142b84222c10ce51b520d7d7136fa08a=MiDKP_e498578b78aa0db9c45f30f87d63debc end local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Item.CreateItem(MiDKP_142b84222c10ce51b520d7d7136fa08a, 0, {player},MiDKP_Options["split_item_points"]) if not MiDKP_8d0febf2348ea712b2b375ae95601d5f then return end if (MiDKP_Options["default_action"] == "notify")or MiDKPMemberPickerFrame:IsVisible() then MiDKP_UIHelp.Notify.AddNotify("item", MiDKP_8d0febf2348ea712b2b375ae95601d5f) elseif (MiDKP_Options["default_action"] == "edit") then local raid = MiDKP_Core.Raid.GetCurrentRaid() if (raid) then MiDKP_UIHelp.General.ShowEditPage("item", "@"..MiDKP_8d0febf2348ea712b2b375ae95601d5f, {player}, raid["items"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["item"], raid["items"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["point"], true,nil,nil,nil,MiDKP_Options["split_item_points"]) end end end end end, ZoneChangeHandler=function() if (not MiDKP_Core.Raid.IsRaidRunning()) then return end local zone = GetRealZoneText() if (zone and MiDKP_6700ce7638ed1dc98ada34b035892167["zones"][zone] and MiDKP_Core.Raid.IsRaidValid()) then MiDKP_Core.Raid.AddRaidPlace(zone) end end, RaidUpdateHandler=function() if (not MiDKP_Core.Raid.IsRaidRunning()) then return end local raid = MiDKP_Core.Raid.GetCurrentRaid() MiDKP_Core.Member.UpdateMembers() local MiDKP_d58ac836bc6b5187396c70101aee40b8=MiDKP_Util:GetRaidMemberSnapshot() local MiDKP_1210e713fbe7372fde7a5518a1f280ec,MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3 = MiDKP_Util:CompareMember(raid["snapshot"],MiDKP_d58ac836bc6b5187396c70101aee40b8) raid["snapshot"]=MiDKP_d58ac836bc6b5187396c70101aee40b8 if (MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3=="JOIN") then MiDKP_Core.Member.ClearEndTime(MiDKP_1210e713fbe7372fde7a5518a1f280ec) if(MiDKP_Core.Member.HasStartTime(MiDKP_1210e713fbe7372fde7a5518a1f280ec)) then else MiDKP_Core.Member.SetStartTime(MiDKP_1210e713fbe7372fde7a5518a1f280ec) end elseif(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3=="LEAVE") then MiDKP_Core.Member.SetEndTime(MiDKP_1210e713fbe7372fde7a5518a1f280ec) end end, MonsterEmoteHandler=function(...) if (not MiDKP_Core.Raid.IsRaidRunning()) then return end local msg = ... if (MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["emote"][msg]) then local members = MiDKP_Core.Member.GetMembersArray(MiDKP_Options["default_member_filter"], MiDKP_Options["member_record_disconnected"]) local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Raid.CreateEvent(string.format(MIDKP_TEXT_FINISH_EVENT, MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["emote"][msg]), 0, members, MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["emote"][msg],true) if (MiDKP_Options["default_action"] == "notify") or MiDKPMemberPickerFrame:IsVisible()then MiDKP_UIHelp.Notify.AddNotify("event", MiDKP_8d0febf2348ea712b2b375ae95601d5f) elseif (MiDKP_Options["default_action"] == "edit") then local raid = MiDKP_Core.Raid.GetCurrentRaid() if (raid) then MiDKP_UIHelp.General.ShowEditPage("event", "@"..MiDKP_8d0febf2348ea712b2b375ae95601d5f, members, raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"], raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["point"],nil,raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"],true,true) end end end end, LootOpenHandler=function() if (not MiDKP_Core.Raid.IsRaidRunning()) then return end local name = UnitName("target") if (MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["loot"][name]) then local members = MiDKP_Core.Member.GetMembersArray(MiDKP_Options["default_member_filter"], MiDKP_Options["member_record_disconnected"]) if (type(MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["loot"][name]) == "string") then local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Raid.CreateEvent(string.format(MIDKP_TEXT_FINISH_EVENT, MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["loot"][name]), 0, members, MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["loot"][name],true) if (MiDKP_Options["default_action"] == "notify") or MiDKPMemberPickerFrame:IsVisible() then MiDKP_UIHelp.Notify.AddNotify("event", MiDKP_8d0febf2348ea712b2b375ae95601d5f) elseif (MiDKP_Options["default_action"] == "edit") then local raid = MiDKP_Core.Raid.GetCurrentRaid() if (raid) then MiDKP_UIHelp.General.ShowEditPage("event", "@"..MiDKP_8d0febf2348ea712b2b375ae95601d5f, members, raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"], raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["point"]) end end else local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Raid.CreateEvent(string.format(MIDKP_TEXT_FINISH_EVENT, name), 0, members, name,true) if (MiDKP_Options["default_action"] == "notify") or MiDKPMemberPickerFrame:IsVisible() then MiDKP_UIHelp.Notify.AddNotify("event", MiDKP_8d0febf2348ea712b2b375ae95601d5f) elseif (MiDKP_Options["default_action"] == "edit") then local raid = MiDKP_Core.Raid.GetCurrentRaid() if (raid) then MiDKP_UIHelp.General.ShowEditPage("event", "@"..MiDKP_8d0febf2348ea712b2b375ae95601d5f, members, raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"], raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["point"]) end end end end end, ChatMsgHandler=function(...) local msg, player = ... local MiDKP_2bed8941fbef02509400ac7bc5ad1ce3 msg = string.lower(msg) local command = "dkp" if command =="" then return end if (msg and msg ~= command) then local MiDKP_6e4d0db7491d6883f86de390d20dbe5b, MiDKP_a2f3972c23a0aa3bd7fb0e9823d918f2 local MiDKP_a8858383576d7634cceceaf04a2ddb29 = "^"..command .. " ([^ ]*)" MiDKP_6e4d0db7491d6883f86de390d20dbe5b, MiDKP_a2f3972c23a0aa3bd7fb0e9823d918f2, MiDKP_2bed8941fbef02509400ac7bc5ad1ce3 = string.find(msg, MiDKP_a8858383576d7634cceceaf04a2ddb29) end local MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af = MiDKP_Core.Raid.GetCurrentRaid() local MiDKP_55e09f5efcb2d3d3db7e87da1edfb273=function() MiDKP_Core.Util.SendWhisperMessage(MIDKP_TEXT_MEMBER_INFO_HELP_MESSAGE, player) if MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af then MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_RAID_NAME_INFO, MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["name"]), player) if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["events"]) then local event_msg local k, v local index = 1 for k, v in pairs(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["events"]) do if (v["point"] and v["point"] ~= 0 and v["players"]) then local show local k1, v1 for k1, v1 in ipairs(v["players"]) do if (v1 == player) then show = true break end end if (show) then if (not event_msg) then MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_EVENT_INFO), player) event_msg = true end MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_EVENT_INFO2, index, v["desc"], v["point"]), player) index = index + 1 end end end end if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["items"]) then local item_msg = nil local k, v local index = 1 for k, v in pairs(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["items"]) do if (v["point"] and v["point"] ~= 0 and v["players"]) then local show local k1, v1 for k1, v1 in ipairs(v["players"]) do if (v1 == player) then show = true break end end if (show) then if (not item_msg) then MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_ITEM_INFO), player) item_msg = true end MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_ITEM_INFO2, index, v["item"], -v["point"]), player) index = index + 1 end end end end if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"][player] and MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"][player]["point"]) then MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_MEMBER_INFO, MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"][player]["point"]), player) end end if (MiDKPData and MiDKPData["dkp"]) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKPData["dkp"]) do if MiDKP_Options["suites"]and MiDKP_Options["suites"][MiDKP_63a9ce6f1eeac72ef41293b7d0303335] then if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af and MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["dkp"] and MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"]==MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["dkp"])then local MiDKP_8d66b86b985300b0b02587d40ca441ad = MiDKP_Core.Util.DataGetMembers(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["dkp"]) if (MiDKP_8d66b86b985300b0b02587d40ca441ad and MiDKP_8d66b86b985300b0b02587d40ca441ad[player]) then if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"][player] and MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"][player]["point"]) then MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_MEMBER_CURRENT_TOTAL,MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"], MiDKP_Util:GetElementPoint(MiDKP_8d66b86b985300b0b02587d40ca441ad[player]),MiDKP_Util:GetElementPoint(MiDKP_8d66b86b985300b0b02587d40ca441ad[player]) + MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"][player]["point"]), player) else MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_MEMBER_INFO5,MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"], MiDKP_Util:GetElementPoint(MiDKP_8d66b86b985300b0b02587d40ca441ad[player])), player) end else MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_MEMBER_INFO5,MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"], 0), player) end else local MiDKP_8d66b86b985300b0b02587d40ca441ad = MiDKP_Core.Util.DataGetMembers(MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"]) if (MiDKP_8d66b86b985300b0b02587d40ca441ad and MiDKP_8d66b86b985300b0b02587d40ca441ad[player]) then MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_MEMBER_INFO5,MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"], MiDKP_Util:GetElementPoint(MiDKP_8d66b86b985300b0b02587d40ca441ad[player])), player) else MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_MEMBER_INFO5,MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"], 0), player) end end end end end MiDKP_Core.Util.SendWhisperMessage(MIDKP_TEXT_MEMBER_INFO_AD, player) end if (player and msg == string.lower(MiDKP_Options["whisper_command"])) then MiDKP_55e09f5efcb2d3d3db7e87da1edfb273() elseif (player and (MiDKP_2bed8941fbef02509400ac7bc5ad1ce3 or msg == command)) then if MiDKP_2bed8941fbef02509400ac7bc5ad1ce3=="help" then MiDKP_Core.Util.SendWhisperMessage(MIDKP_TEXT_MEMBER_HELP_MESSAGE_TEXT, player) return end local MiDKP_b962f54280c77029bc350c2b321adc64 local MiDKP_3b73afab589ef88b2cab823d2b3c8239 local MiDKP_8f81cccca434aa7ae8e147d0fcfb685f = MiDKP_Util:GetPoint(MiDKP_2bed8941fbef02509400ac7bc5ad1ce3, true) if (MiDKP_8f81cccca434aa7ae8e147d0fcfb685f) then if (MiDKPData and MiDKPData["dkp"] and MiDKPData["dkp"][MiDKP_8f81cccca434aa7ae8e147d0fcfb685f]) then local MiDKP_8d66b86b985300b0b02587d40ca441ad = MiDKPData["dkp"][MiDKP_8f81cccca434aa7ae8e147d0fcfb685f]["members"] if (MiDKP_8d66b86b985300b0b02587d40ca441ad and MiDKP_8d66b86b985300b0b02587d40ca441ad[player]) then MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_MEMBER_INFO5, MiDKPData["dkp"][MiDKP_8f81cccca434aa7ae8e147d0fcfb685f]["name"], MiDKP_8d66b86b985300b0b02587d40ca441ad[player]["score"] or MiDKP_8d66b86b985300b0b02587d40ca441ad[player]), player) else MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_NO_RECORD, MiDKPData["dkp"][MiDKP_8f81cccca434aa7ae8e147d0fcfb685f]["name"]), player) end end return end if (not MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af) then MiDKP_Core.Util.SendWhisperMessage(MIDKP_TEXT_NO_RAID, player) return end if (not MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["start"]) then MiDKP_Core.Util.SendWhisperMessage(MIDKP_TEXT_RAID_NO_START, player) return end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MIDKP_CLASS) do if (MiDKP_2bed8941fbef02509400ac7bc5ad1ce3 ==MiDKP_8d0644c92128c1ff68223fd74ba63b56.shortcut or MiDKP_2bed8941fbef02509400ac7bc5ad1ce3==MiDKP_8d0644c92128c1ff68223fd74ba63b56.text1 or MiDKP_2bed8941fbef02509400ac7bc5ad1ce3==MiDKP_8d0644c92128c1ff68223fd74ba63b56.text2) then MiDKP_b962f54280c77029bc350c2b321adc64 = MiDKP_8d0644c92128c1ff68223fd74ba63b56.name MiDKP_3b73afab589ef88b2cab823d2b3c8239 = MiDKP_8d0644c92128c1ff68223fd74ba63b56.text1 break end end if ( MiDKP_b962f54280c77029bc350c2b321adc64) then if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"]) then local index = 1 local k, v local exist local point = 0 local MiDKP_8d66b86b985300b0b02587d40ca441ad = MiDKP_Core.Util.DataGetMembers(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["dkp"]) for k, v in pairs(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"]) do point = 0 if (v["class"] and v["class"] == MiDKP_b962f54280c77029bc350c2b321adc64) then if (MiDKP_8d66b86b985300b0b02587d40ca441ad and MiDKP_8d66b86b985300b0b02587d40ca441ad[k]) then point = MiDKP_Util:GetElementPoint(MiDKP_8d66b86b985300b0b02587d40ca441ad[k]) end if (not v["point"]) then v["point"] = 0 end if (not exist) then MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_MEMBER_INFO3, MiDKP_3b73afab589ef88b2cab823d2b3c8239), player) exist = true end MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_MEMBER_INFO4, index, k, point + v["point"]), player) index = index + 1 point = point + v["point"] end end if (not exist) then MiDKP_Core.Util.SendWhisperMessage(string.format(MIDKP_TEXT_RAID_NO_MEMBER_INFO, MiDKP_3b73afab589ef88b2cab823d2b3c8239), player) end end end end end, AddonLoadHandler=function(...) local addon = ... if (addon == "MiDKP") then MiDKP_UIHelp.Util.MiniButton_SetPosition() MiDKP_Core.Util.RegisterMod(MiDKPFrame) MiDKPRaidPage:SetFrameLevel(7) MiDKPMemberPage:SetFrameLevel(7) MiDKPEventPage:SetFrameLevel(7) MiDKPItemPage:SetFrameLevel(7) MiDKPRaidPage:Show() MiDKP_Core.Item.BuildIgnoreItemsIndex() end end, CombatLogHandler=function(...) if (not MiDKP_Core.Raid.IsRaidRunning()) then return end local timestamp, event, sguid, sname, sflags, dguid, dname, dflags = ... if (event == "UNIT_DIED") then if (dname) then local MiDKP_1a4a3c7a1fdba9319ea8aff717f9c2e0 = GetRealZoneText() if (MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["kill"][MiDKP_1a4a3c7a1fdba9319ea8aff717f9c2e0] and MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["kill"][MiDKP_1a4a3c7a1fdba9319ea8aff717f9c2e0][dname]) then local members = MiDKP_Core.Member.GetMembersArray(MiDKP_Options["default_member_filter"], MiDKP_Options["member_record_disconnected"]) if (type(MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["kill"][MiDKP_1a4a3c7a1fdba9319ea8aff717f9c2e0][dname]) == "string") then local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Raid.CreateEvent(string.format(MIDKP_TEXT_FINISH_EVENT, MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["kill"][MiDKP_1a4a3c7a1fdba9319ea8aff717f9c2e0][dname]), 0, members, dname,true) if (MiDKP_Options["default_action"] == "notify")or MiDKPMemberPickerFrame:IsVisible() then MiDKP_UIHelp.Notify.AddNotify("event", MiDKP_8d0febf2348ea712b2b375ae95601d5f) elseif (MiDKP_Options["default_action"] == "edit") then local raid = MiDKP_Core.Raid.GetCurrentRaid() if (raid) then MiDKP_UIHelp.General.ShowEditPage("event", "@"..MiDKP_8d0febf2348ea712b2b375ae95601d5f, members, raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"], raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["point"],nil,raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"],true,true) end end else local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Raid.CreateEvent(string.format(MIDKP_TEXT_FINISH_EVENT, dname), 0, members, dname,true) if (MiDKP_Options["default_action"] == "notify") or MiDKPMemberPickerFrame:IsVisible() then MiDKP_UIHelp.Notify.AddNotify("event", MiDKP_8d0febf2348ea712b2b375ae95601d5f) elseif (MiDKP_Options["default_action"] == "edit") then local raid = MiDKP_Core.Raid.GetCurrentRaid() if (raid) then MiDKP_UIHelp.General.ShowEditPage("event", "@"..MiDKP_8d0febf2348ea712b2b375ae95601d5f, members, raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"], raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["point"],nil,raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"],true,true) end end end end if (MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["multikill"][MiDKP_1a4a3c7a1fdba9319ea8aff717f9c2e0]) then local boss, monsters for boss, monsters in pairs(MiDKP_6700ce7638ed1dc98ada34b035892167["bosses"]["multikill"][MiDKP_1a4a3c7a1fdba9319ea8aff717f9c2e0]) do if (monsters[dname]) then local mname, mvalue if (not MiDKP_BossKillTemp[boss]) then MiDKP_BossKillTemp[boss] = {} for mname, mvalue in pairs(monsters) do MiDKP_BossKillTemp[boss][mname] = false end end MiDKP_BossKillTemp[boss][dname] = true local done = true for mname, mvalue in pairs(MiDKP_BossKillTemp[boss]) do if (mvalue == false) then done = false end end if (done) then local members = MiDKP_Core.Member.GetMembersArray(MiDKP_Options["default_member_filter"], MiDKP_Options["member_record_disconnected"]) local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Raid.CreateEvent(string.format(MIDKP_TEXT_FINISH_EVENT, boss), 0, members, boss,true) if (MiDKP_Options["default_action"] == "notify") or MiDKPMemberPickerFrame:IsVisible()then MiDKP_UIHelp.Notify.AddNotify("event", MiDKP_8d0febf2348ea712b2b375ae95601d5f) elseif (MiDKP_Options["default_action"] == "edit") then local raid = MiDKP_Core.Raid.GetCurrentRaid() if (raid) then MiDKP_UIHelp.General.ShowEditPage("event", "@"..MiDKP_8d0febf2348ea712b2b375ae95601d5f, members, raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"], raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["point"],nil,raid["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"],true,true) end end end end end end end end end, ChatFrameMessageEventHandler=function(ui,event, ...) local msg, sender = ... if (msg and sender) then local id = msg .. ":" .. sender if (event == "CHAT_MSG_AFK" or event == "CHAT_MSG_DND") then if (MiDKP_AFKDND[sender]) then return end end if (event == "CHAT_MSG_WHISPER_INFORM" and MiDKP_HiddenWhisper[id] and MiDKP_Options["hide_whisper_reply"]) then return end end MiDKP_Old_ChatFrame_MessageEventHandler(ui,event, ...) end, SlashCommandHandler=function(cmd,editbox) if (MiDKPMainFrame and (not MiDKPMainFrame:IsShown()) ) then ShowUIPanel(MiDKPMainFrame) end end, } MiDKP_UI={} MiDKP_UI.Frame={ OnFrameUpdate=function(ui_element,elapsed) MiDKPFrame.time = MiDKPFrame.time + elapsed if (MiDKPFrame.time > 0.5) then MiDKPFrame.time = 0 local k, v for k, v in pairs(MiDKP_AFKDND) do if (GetTime() - v > 0.5) then MiDKP_AFKDND[k] = nil end end end MiDKP_UIHelp.Notify.SetAllNotifyButtonGlow() end, OnFrameLoad=function(ui_element) MIDKP_LOOT_ITEM = MiDKP_Util:String2Pattern(LOOT_ITEM) MIDKP_LOOT_ITEM_MULTIPLE = MiDKP_Util:String2Pattern(LOOT_ITEM_MULTIPLE) MIDKP_LOOT_ITEM_SELF = MiDKP_Util:String2Pattern(LOOT_ITEM_SELF) MIDKP_LOOT_ITEM_SELF_MULTIPLE = MiDKP_Util:String2Pattern(LOOT_ITEM_SELF_MULTIPLE) MIDKP_LOOT_ITEM_PUSHED_SELF = MiDKP_Util:String2Pattern(LOOT_ITEM_PUSHED_SELF) MIDKP_LOOT_ITEM_PUSHED_SELF_MULTIPLE = MiDKP_Util:String2Pattern(LOOT_ITEM_PUSHED_SELF_MULTIPLE) ui_element:RegisterEvent("ADDON_LOADED") ui_element.time = 0 end, OnFrameEvent=function(ui_element, event, ...) if (event == "CHAT_MSG_LOOT") then MiDKP_Event.ChatMsgLootHandler(...) elseif (event == "ZONE_CHANGED_NEW_AREA") then MiDKP_Event.ZoneChangeHandler() elseif (event == "RAID_ROSTER_UPDATE") then MiDKP_Event.RaidUpdateHandler() elseif (event == "COMBAT_LOG_EVENT_UNFILTERED") then MiDKP_Event.CombatLogHandler(...) elseif (event == "CHAT_MSG_MONSTER_EMOTE" or event == "CHAT_MSG_MONSTER_YELL") then MiDKP_Event.MonsterEmoteHandler(...) elseif (event == "ADDON_LOADED") then MiDKP_Event.AddonLoadHandler(...) elseif (event == "LOOT_OPENED") then MiDKP_Event.LootOpenHandler() elseif (event == "PLAYER_REGEN_DISABLED" or event == "PLAYER_REGEN_ENABLED") then MiDKP_BossKillTemp = {} elseif (event == "CHAT_MSG_WHISPER") then MiDKP_Event.ChatMsgHandler(...) end end, TabInit=function() MiDKPMainFrameTab1:SetText(MIDKP_TEXT_TAB_RAID) MiDKPMainFrameTab2:SetText(MIDKP_TEXT_TAB_MEMBER) MiDKPMainFrameTab3:SetText(MIDKP_TEXT_TAB_EVENT) MiDKPMainFrameTab4:SetText(MIDKP_TEXT_TAB_ITEM) MiDKPMainFrameTab5:SetText(MIDKP_TEXT_TAB_OPTION) MiDKPMainFrameTab6:SetText(MIDKP_TEXT_TAB_DKP) end, } MiDKP_UI.Notify={ OnNotifyLoad=function(ui_element) ui_element:RegisterForClicks("LeftButtonUp", "RightButtonUp") end, OnNotifyEnter=function(ui_element) if (ui_element.text) then GameTooltip:SetOwner(ui_element, "TOPLEFT") GameTooltip:SetText(ui_element.text) GameTooltip:Show() end end, OnNotifyLeave=function(ui_element) GameTooltip:Hide() end, OnNotifyClick=function(ui_element, button) if (button == "LeftButton") then local category = ui_element.category local id = ui_element.id local raid = MiDKP_Core.Raid.GetCurrentRaid() local members = {} if (not raid or not id) then ui_element:Hide() return end if (raid["end"]) then ui_element:Hide() return end if (category == "event") then members = raid["events"][id]["players"] if (MiDKP_Util:IsTableNotEmpty(members)) then MiDKP_UIHelp.General.ShowEditPage("event", "@"..id, members, raid["events"][id]["desc"], raid["events"][id]["point"],nil,raid["events"][id]["desc"],true,true) else MiDKP_UIHelp.General.ShowEditPage("event", "@"..id, {}, raid["events"][id]["desc"], raid["events"][id]["point"],nil,raid["events"][id]["desc"],true,true) end elseif (category == "item") then members = raid["items"][id]["players"] if (MiDKP_Util:IsTableNotEmpty(members)) then MiDKP_UIHelp.General.ShowEditPage("item", "@"..id, members, raid["items"][id]["item"], raid["items"][id]["point"],true,nil,nil,nil,MiDKP_Options["split_item_points"]) else MiDKP_UIHelp.General.ShowEditPage("item", "@"..id, {}, raid["items"][id]["item"], raid["items"][id]["point"],true,nil,nil,nil,MiDKP_Options["split_item_points"]) end end end MiDKP_UIHelp.Notify.SetNotifyLocation(ui_element) end, } MiDKP_UI.Raid={ OnRaidShow=function() MiDKP_UIHelp.Raid.DoUpdate() end, ActiveButton_OnClick=function(ui_element) local MiDKP_1346009d8936868590c1d007e3efcfae = ui_element:GetParent():GetParent() if not MiDKP_Core.Raid.ActiveRaid(MiDKP_1346009d8936868590c1d007e3efcfae.index) then return end MiDKP_UIHelp.Raid.DoUpdate() MiDKP_UIHelp.Raid.ResetRaidPages() local MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af = MiDKP_Core.Raid.GetCurrentRaid() if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af) then MiDKP_Util:Print("info", MIDKP_TEXT_CHANGE_RAID, MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["name"]) end end, RaidButton_OnEnter=function(ui_element) MiDKP_UIHelp.Raid.RaidButton_Update(ui_element) end, RaidButton_OnLeave=function(ui_element) MiDKP_UIHelp.Raid.RaidButton_Update(ui_element) end, RaidEditFrameOK_OnClick=function(ui_element) local MiDKP_8983c60d66c8593ec7165ea9dbedb584 = MiDKPRaidEditFrameText:GetText() if (MiDKP_8983c60d66c8593ec7165ea9dbedb584 == "") then MiDKP_Util:Print("error", MIDKP_TEXT_SPECIFY_RAID) return end local k, v local MiDKP_f8c6f4951c524600d5984ab47a0d8393 for k, v in pairs(MiDKPRaidEditFrame.used_buttons) do if (v:GetChecked()) then MiDKP_f8c6f4951c524600d5984ab47a0d8393 = v.text end end if not MiDKP_f8c6f4951c524600d5984ab47a0d8393 and MiDKPData and MiDKPData[1] and not MiDKPData[2] then MiDKP_f8c6f4951c524600d5984ab47a0d8393 = MiDKPData[1].name end if (MiDKPRaidEditFrame.id) then MiDKP_Core.Raid.ModifyRaid("@"..MiDKPRaidEditFrame.id, MiDKP_8983c60d66c8593ec7165ea9dbedb584, MiDKP_f8c6f4951c524600d5984ab47a0d8393) else local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Raid.CreateRaid(MiDKP_8983c60d66c8593ec7165ea9dbedb584, MiDKP_f8c6f4951c524600d5984ab47a0d8393) end MiDKPRaidEditFrame:Hide() if (MiDKPRaidPage:IsShown()) then MiDKP_UIHelp.Raid.DoUpdate() end end, RaidButton_OnClick=function(ui_element, button) local MiDKP_1346009d8936868590c1d007e3efcfae = ui_element:GetParent() local id = ui_element:GetID() local page = MiDKP_1346009d8936868590c1d007e3efcfae.page or 1 getglobal(ui_element:GetName().."Info"):Show() getglobal(ui_element:GetName().."Status"):Show() MiDKP_1346009d8936868590c1d007e3efcfae.index = (page - 1) * MIDKP_RAID_PAGE_COUNT + id MiDKP_UIHelp.Raid.DoUpdate() MiDKP_UIHelp.Raid.ResetRaidPages() end, ActionButton_OnClick=function(ui_element) local MiDKP_1346009d8936868590c1d007e3efcfae = ui_element:GetParent() local index = MiDKP_1346009d8936868590c1d007e3efcfae.index local page = MiDKP_1346009d8936868590c1d007e3efcfae.page or 1 local text = ui_element:GetText() if (index) then if (text == MIDKP_TEXT_RAID_START) then MiDKP_Core.Raid.StartRaid(index) elseif (text == MIDKP_TEXT_RAID_END) then MiDKP_Core.Raid.EndRaid(index) elseif (text == MIDKP_TEXT_RAID_EXPORT) then MiDKPExportFrameText.text = MiDKP_Core.Raid.ExportRaid(index) MiDKPExportFrame:Show() end MiDKP_UIHelp.Raid.DoUpdate() end end, DeleteButton_OnClick=function(ui_element) local MiDKP_1346009d8936868590c1d007e3efcfae = _G.MiDKPRaidPage if (MiDKP_1346009d8936868590c1d007e3efcfae.index) then local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Util.GetID("raid", MiDKP_1346009d8936868590c1d007e3efcfae.index) if MiDKP_Config.raids and MiDKP_Config.raids[MiDKP_8d0febf2348ea712b2b375ae95601d5f] then StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_RAID].raid_id = MiDKP_8d0febf2348ea712b2b375ae95601d5f MiDKP_Util:SafePopup_Show(MiDKP_DIALOG_CONFIRM_DELETE_RAID) end end end, CreateButton_OnClick=function(ui_element) MiDKP_UIHelp.Raid.ShowRaidEditFrame() end, ModifyButton_OnClick=function(ui_element) local id = MiDKP_Core.Util.GetID("raid", MiDKPRaidPage.index) if (not id) then return end MiDKP_UIHelp.Raid.ShowRaidEditFrame("@"..id) end, } MiDKP_UI.Item={ OnItemShow=function() MiDKP_UIHelp.Item.DoUpdate() end, CreateButton_OnClick=function(ui_element) MiDKP_UIHelp.General.ShowEditPage("item", nil, nil, nil, nil, true,nil,nil,nil,MiDKP_Options["split_item_points"]) end, DeleteButton_OnClick=function(ui_element) local index = MiDKPItemPage.index if (index) then local id = MiDKP_Core.Util.GetID("item", index) local raid = MiDKP_Core.Raid.GetCurrentRaid() StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_ITEM].item_id = id MiDKP_Util:SafePopup_Show(MiDKP_DIALOG_CONFIRM_DELETE_ITEM, raid["items"][id]["item"]) end end, AddToListButton_OnClick=function(ui_element) local index = MiDKPItemPage.index if (index) then local id = MiDKP_Core.Util.GetID("item", index) local raid = MiDKP_Core.Raid.GetCurrentRaid() local text= raid["items"][id]["item"] if text and text ~="" then MiDKP_Core.Item.AddIgnoreItem(text) end end end, ModifyButton_OnClick=function(ui_element) local page = MiDKPItemPage.page or 1 local index = MiDKPItemPage.index local raid = MiDKP_Core.Raid.GetCurrentRaid() local id = MiDKP_Core.Util.GetID("item", index) local members = {} if (not id) then return end members = raid["items"][id]["players"] local MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = 0 local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(members) do MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_3f50417fb16be9b1078eb68d24fa9c26 + 1 end if (MiDKP_3f50417fb16be9b1078eb68d24fa9c26 > 0) then MiDKP_UIHelp.General.ShowEditPage("item", "@"..id, members, raid["items"][id]["item"], raid["items"][id]["point"], true,nil,nil,nil,raid["items"][id]["event"]) else MiDKP_UIHelp.General.ShowEditPage("item", "@"..id, {}, raid["items"][id]["item"], raid["items"][id]["point"], true,nil,nil,nil,raid["items"][id]["event"]) end end, } MiDKP_UI.Member={ OnMemberShow=function() MiDKP_UIHelp.Member.DoUpdate() end, ColumnHeader_OnClick=function(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3) MiDKP_UIHelp.Util.UpdateSortStatus(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3,MiDKP_UIHelp.Member) MiDKP_UIHelp.Member.DoUpdate() end, DeleteButton_OnClick=function(ui_element) local __index = MiDKPMemberPage.index if (__index) then __index = __index - math.floor((__index-1)/MIDKP_MEMBER_PAGE_COUNT)*MIDKP_MEMBER_PAGE_COUNT local name = getglobal("MiDKPMemberPageMember"..__index.."Name"):GetText() if (name) then StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_MEMBER].member_name = name MiDKP_Util:SafePopup_Show(MiDKP_DIALOG_CONFIRM_DELETE_MEMBER, name) end end end, CreateButton_OnClick=function(ui_element) local index = MiDKPMemberPage.index if (index) then index = index - math.floor((index-1)/MIDKP_MEMBER_PAGE_COUNT)*MIDKP_MEMBER_PAGE_COUNT local name = getglobal("MiDKPMemberPageMember"..index.."Name"):GetText() if (name) then MiDKP_UIHelp.General.ShowEditPage("member", nil, {name}) end end end, CreateMemberButton_OnClick=function(ui_element) MiDKPAddMemberFrame.class=MIDKP_CLASS.NAME[1] MiDKP_UIHelp.Member.ShowAddMemberPage() end, AddMemberButton_OnClick=function(ui_element) local MiDKP_1346009d8936868590c1d007e3efcfae = ui_element:GetParent() local MiDKP_2f731006263dd4046d2ee4c1ba8fc1c7=getglobal(MiDKP_1346009d8936868590c1d007e3efcfae:GetName().."Text") for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MIDKP_CLASS.NAME) do getglobal("MiDKPAddMemberFrameClass"..MiDKP_8d0644c92128c1ff68223fd74ba63b56):SetChecked(0) end local MiDKP_e6955c64cf39bdb23dc86de1a9ec2117 =MiDKP_2f731006263dd4046d2ee4c1ba8fc1c7:GetText() if not MiDKP_e6955c64cf39bdb23dc86de1a9ec2117 or MiDKP_e6955c64cf39bdb23dc86de1a9ec2117=="" then MiDKP_Util:Print("error", MIDKP_TEXT_INVALID_PLAYER) return end local MiDKP_da7080deac537a3a7fc5d830c281941d,MiDKP_b962f54280c77029bc350c2b321adc64=MiDKP_Core.Member.AddMember(MiDKP_e6955c64cf39bdb23dc86de1a9ec2117,MiDKP_1346009d8936868590c1d007e3efcfae.class) if(MiDKP_da7080deac537a3a7fc5d830c281941d)then MiDKP_2f731006263dd4046d2ee4c1ba8fc1c7:SetText("") MiDKP_1346009d8936868590c1d007e3efcfae:Hide() elseif MiDKP_b962f54280c77029bc350c2b321adc64 then local MiDKP_aac9299702ac0f65f5729d35589b6c95=string.firstupper(string.lower(MiDKP_b962f54280c77029bc350c2b321adc64)) getglobal("MiDKPAddMemberFrameClass"..MiDKP_aac9299702ac0f65f5729d35589b6c95):SetChecked(1) MiDKP_1346009d8936868590c1d007e3efcfae.class=MiDKP_aac9299702ac0f65f5729d35589b6c95 end MiDKP_UIHelp.Member.DoUpdate() end, } MiDKP_UI.IgnoreItem={ OnIgnoreItemShow=function() FauxScrollFrame_OnVerticalScroll(MiDKPIgnoreItemsFrameScrollFrame, 1, 13, MiDKP_UIHelp.IgnoreItem.DoUpdate) end, Button_OnClick=function(ui_elment,button) local index = ui_elment:GetID() MiDKP_UIHelp.IgnoreItem.SetSelectedIgnoreItem(index) MiDKP_UIHelp.IgnoreItem.DoUpdate() end, FrameDelete_OnClick=function(ui_elment) local MiDKP_935200802c6b9f940519a1822a252c38 = MiDKP_UIHelp.IgnoreItem.GetSelectedIgnoreItem() local MiDKP_e6955c64cf39bdb23dc86de1a9ec2117 = MiDKP_Core.Item.GetIgnoreItemInfo(MiDKP_935200802c6b9f940519a1822a252c38) StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_IGNORE_ITEM].index = MiDKP_935200802c6b9f940519a1822a252c38 MiDKP_Util:SafePopup_Show(MiDKP_DIALOG_CONFIRM_DELETE_IGNORE_ITEM, MiDKP_e6955c64cf39bdb23dc86de1a9ec2117) end, FrameAdd_OnClick=function(ui_elment) MiDKP_Util:SafePopup_Show(MiDKP_DIALOG_CREATE_IGNORE_ITEM) end, FrameDefault_OnClick=function(ui_elment) MiDKP_Util:SafePopup_Show(MiDKP_DIALOG_CONFIRM_RESTORE_IGNORE_ITEMS) end, } MiDKP_UI.Option={ OnOptionUpdate=function() MiDKPOptionPageQualityUncommon:SetChecked(0) MiDKPOptionPageQualityRare:SetChecked(0) MiDKPOptionPageQualityEpic:SetChecked(0) MiDKPOptionPageQualityLegendary:SetChecked(0) if (MiDKP_Options["min_quality"] == 2) then MiDKPOptionPageQualityUncommon:SetChecked(1) elseif (MiDKP_Options["min_quality"] == 3) then MiDKPOptionPageQualityRare:SetChecked(1) elseif (MiDKP_Options["min_quality"] == 4) then MiDKPOptionPageQualityEpic:SetChecked(1) elseif (MiDKP_Options["min_quality"] == 5) then MiDKPOptionPageQualityLegendary:SetChecked(1) else MiDKP_Options["min_quality"] = 3 MiDKPOptionPageQualityRare:SetChecked(1) end if (MiDKP_Options["whisper_command"] == "") then MiDKPOptionPageWhisper:SetChecked(0) MiDKPOptionPageWhisperEditBox:SetText("") MiDKPOptionPageWhisperEditBox:Hide() else MiDKPOptionPageWhisper:SetChecked(1) MiDKPOptionPageWhisperEditBox:SetText(MiDKP_Options["whisper_command"]) MiDKPOptionPageWhisperEditBox:Show() end if (MiDKP_Options["hide_whisper_reply"]) then MiDKPOptionPageHideWhisper:SetChecked(1) else MiDKPOptionPageHideWhisper:SetChecked(0) end MiDKPOptionPageWhisperEditBox.text = MiDKPOptionPageWhisperEditBox:GetText() MiDKPOptionPageWhisperEditBox.pos = MiDKPOptionPageWhisperEditBox:GetCursorPosition() MiDKPOptionPageEventActionNoAction:SetChecked(0) MiDKPOptionPageEventActionTipOnly:SetChecked(0) MiDKPOptionPageEventActionShowEdit:SetChecked(0) if (MiDKP_Options["default_action"] == "noaction") then MiDKPOptionPageEventActionNoAction:SetChecked(1) elseif (MiDKP_Options["default_action"] == "notify") then MiDKPOptionPageEventActionTipOnly:SetChecked(1) elseif (MiDKP_Options["default_action"] == "edit") then MiDKPOptionPageEventActionShowEdit:SetChecked(1) else MiDKP_Options["default_action"] = "notify" MiDKPOptionPageEventActionNoAction:SetChecked(1) end MiDKPOptionPageEventMemberFirst5:SetChecked(0) MiDKPOptionPageEventMemberRaid:SetChecked(0) MiDKPOptionPageEventMemberAll:SetChecked(0) if (MiDKP_Options["default_member_filter"] == "first5") then MiDKPOptionPageEventMemberFirst5:SetChecked(1) elseif (MiDKP_Options["default_member_filter"] == "raid") then MiDKPOptionPageEventMemberRaid:SetChecked(1) elseif (MiDKP_Options["default_member_filter"] == "all") then MiDKPOptionPageEventMemberAll:SetChecked(1) end if (MiDKP_Options["member_record_disconnected"]) then MiDKPOptionPageEventMemberDisconnected:SetChecked(1) else MiDKPOptionPageEventMemberDisconnected:SetChecked(0) end if (MiDKP_Options["split_item_points"]) then MiDKPOptionPagePointsSplit:SetChecked(1) else MiDKPOptionPagePointsSplit:SetChecked(0) end end, IgnoreItemsButton_OnClick=function() MiDKPIgnoreItemsFrame:Show() end, QualityUncommon_OnClick=function() MiDKPOptionPageQualityUncommon:SetChecked(1) MiDKPOptionPageQualityRare:SetChecked(0) MiDKPOptionPageQualityEpic:SetChecked(0) MiDKPOptionPageQualityLegendary:SetChecked(0) MiDKP_UIHelp.Util.OptionPage_Commit() end, QualityRare_OnClick=function() MiDKPOptionPageQualityUncommon:SetChecked(0) MiDKPOptionPageQualityRare:SetChecked(1) MiDKPOptionPageQualityEpic:SetChecked(0) MiDKPOptionPageQualityLegendary:SetChecked(0) MiDKP_UIHelp.Util.OptionPage_Commit() end, QualityEpic_OnClick=function() MiDKPOptionPageQualityUncommon:SetChecked(0) MiDKPOptionPageQualityRare:SetChecked(0) MiDKPOptionPageQualityEpic:SetChecked(1) MiDKPOptionPageQualityLegendary:SetChecked(0) MiDKP_UIHelp.Util.OptionPage_Commit() end, QualityLegendary_OnClick=function() MiDKPOptionPageQualityUncommon:SetChecked(0) MiDKPOptionPageQualityRare:SetChecked(0) MiDKPOptionPageQualityEpic:SetChecked(0) MiDKPOptionPageQualityLegendary:SetChecked(1) MiDKP_UIHelp.Util.OptionPage_Commit() end, Whisper_OnClick=function() if (MiDKPOptionPageWhisper:GetChecked()) then MiDKPOptionPageWhisperEditBox:Show() MiDKPOptionPageWhisperEditBox:SetFocus() MiDKPOptionPageWhisperEditBox.text = MiDKPOptionPageWhisperEditBox:GetText() MiDKPOptionPageWhisperEditBox.pos = MiDKPOptionPageWhisperEditBox:GetCursorPosition() else MiDKPOptionPageWhisperEditBox:Hide() end MiDKP_UIHelp.Util.OptionPage_Commit() end, EventActionNoAction_OnClick=function() MiDKPOptionPageEventActionNoAction:SetChecked(1) MiDKPOptionPageEventActionTipOnly:SetChecked(0) MiDKPOptionPageEventActionShowEdit:SetChecked(0) MiDKP_UIHelp.Util.OptionPage_Commit() end, EventActionTipOnly_OnClick=function() MiDKPOptionPageEventActionNoAction:SetChecked(0) MiDKPOptionPageEventActionTipOnly:SetChecked(1) MiDKPOptionPageEventActionShowEdit:SetChecked(0) MiDKP_UIHelp.Util.OptionPage_Commit() end, EventActionShowEdit_OnClick=function() MiDKPOptionPageEventActionNoAction:SetChecked(0) MiDKPOptionPageEventActionTipOnly:SetChecked(0) MiDKPOptionPageEventActionShowEdit:SetChecked(1) MiDKP_UIHelp.Util.OptionPage_Commit() end, EventMemberFirst5_OnClick=function() MiDKPOptionPageEventMemberFirst5:SetChecked(1) MiDKPOptionPageEventMemberRaid:SetChecked(0) MiDKPOptionPageEventMemberAll:SetChecked(0) MiDKPOptionPageEventMemberDisconnected:Enable() MiDKP_UIHelp.Util.OptionPage_Commit() end, EventMemberRaid_OnClick=function() MiDKPOptionPageEventMemberFirst5:SetChecked(0) MiDKPOptionPageEventMemberRaid:SetChecked(1) MiDKPOptionPageEventMemberAll:SetChecked(0) MiDKPOptionPageEventMemberDisconnected:Enable() MiDKP_UIHelp.Util.OptionPage_Commit() end, EventMemberAll_OnClick=function() MiDKPOptionPageEventMemberFirst5:SetChecked(0) MiDKPOptionPageEventMemberRaid:SetChecked(0) MiDKPOptionPageEventMemberAll:SetChecked(1) MiDKPOptionPageEventMemberDisconnected:SetChecked(1) MiDKPOptionPageEventMemberDisconnected:Disable() MiDKP_UIHelp.Util.OptionPage_Commit() end, EventMemberDisconnected_OnClick=function() MiDKP_UIHelp.Util.OptionPage_Commit() end, HideWhisper_OnClick=function() MiDKP_UIHelp.Util.OptionPage_Commit() end, WhisperEditBox_OnTextChanged=function(ui_element) local text = MiDKPOptionPageWhisperEditBox:GetText() if (string.find(text, "^[a-zA-Z0-9]+$") or text == "") then MiDKPOptionPageWhisperEditBox.text = text MiDKPOptionPageWhisperEditBox.pos = MiDKPOptionPageWhisperEditBox:GetCursorPosition() MiDKP_UIHelp.Util.OptionPage_Commit() else MiDKPOptionPageWhisperEditBox:SetText(MiDKPOptionPageWhisperEditBox.text) MiDKPOptionPageWhisperEditBox:SetCursorPosition(MiDKPOptionPageWhisperEditBox.pos) end end, PointsSplit_OnClick=function(ui_element) MiDKP_UIHelp.Util.OptionPage_Commit() end, } MiDKP_UI.Event={ OnEventShow=function(ui_element) MiDKP_UIHelp.Event.DoUpdate() end, DeleteButton_OnClick=function( ui_element) local index = MiDKPEventPage.index if (index) then local id = MiDKP_Core.Util.GetID("event", index) local raid = MiDKP_Core.Raid.GetCurrentRaid() StaticPopupDialogs[MiDKP_DIALOG_CONFIRM_DELETE_EVENT].event_id = id MiDKP_Util:SafePopup_Show(MiDKP_DIALOG_CONFIRM_DELETE_EVENT, raid["events"][id]["desc"]) end end, CreateButton_OnClick=function( ui_element) MiDKP_UIHelp.General.ShowEditPage("event") end, ModifyButton_OnClick=function( ui_element) local page = MiDKPEventPage.page or 1 local index = MiDKPEventPage.index local raid = MiDKP_Core.Raid.GetCurrentRaid() local id = MiDKP_Core.Util.GetID("event", index) local members = {} if (not id) then return end members = raid["events"][id]["players"] local MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = 0 local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(members) do MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_3f50417fb16be9b1078eb68d24fa9c26 + 1 end if (MiDKP_3f50417fb16be9b1078eb68d24fa9c26 > 0) then MiDKP_UIHelp.General.ShowEditPage("event", "@"..id, members, raid["events"][id]["desc"], raid["events"][id]["point"],nil,raid["events"][id]["boss"],raid["events"][id]["auto"],nil,raid["events"][id]["item"]) else MiDKP_UIHelp.General.ShowEditPage("event", "@"..id, {}, raid["events"][id]["desc"], raid["events"][id]["point"],nil,raid["events"][id]["boss"],raid["events"][id]["auto"],nil,raid["events"][id]["item"]) end end, } MiDKP_UI.Announce={ OnAnnounceShow=function(ui_element) MiDKPAnnounceFrameRaidChannel:SetChecked(ui_element.raidchannel ) MiDKPAnnounceFrameGuildChannel:SetChecked(ui_element.guildchannel) MiDKPAnnounceFrameOfficerChannel:SetChecked(ui_element.officerchannel ) MiDKPAnnounceFramePartyChannel:SetChecked(ui_element.partychannel) MiDKPAnnounceFrameEvent:SetChecked(ui_element.event) MiDKPAnnounceFrameItem:SetChecked(ui_element.item) MiDKPAnnounceFrameMembers:SetChecked(ui_element.members) MiDKP_UIHelp.Util.UpdateButtonState() end, RaidChannel_OnClick=function(ui_element) MiDKPAnnounceFrameRaidChannel:SetChecked(1) MiDKPAnnounceFrameGuildChannel:SetChecked(0) MiDKPAnnounceFrameOfficerChannel:SetChecked(0) MiDKPAnnounceFramePartyChannel:SetChecked(0) MiDKP_UIHelp.Util.UpdateButtonState() end, GuildChannel_OnClick=function(ui_element) MiDKPAnnounceFrameRaidChannel:SetChecked(0) MiDKPAnnounceFrameGuildChannel:SetChecked(1) MiDKPAnnounceFrameOfficerChannel:SetChecked(0) MiDKPAnnounceFramePartyChannel:SetChecked(0) MiDKP_UIHelp.Util.UpdateButtonState() end, OfficerChannel_OnClick=function(ui_element) MiDKPAnnounceFrameRaidChannel:SetChecked(0) MiDKPAnnounceFrameGuildChannel:SetChecked(0) MiDKPAnnounceFrameOfficerChannel:SetChecked(1) MiDKPAnnounceFramePartyChannel:SetChecked(0) MiDKP_UIHelp.Util.UpdateButtonState() end, PartyChannel_OnClick=function(ui_element) MiDKPAnnounceFrameRaidChannel:SetChecked(0) MiDKPAnnounceFrameGuildChannel:SetChecked(0) MiDKPAnnounceFrameOfficerChannel:SetChecked(0) MiDKPAnnounceFramePartyChannel:SetChecked(1) MiDKP_UIHelp.Util.UpdateButtonState() end, Members_OnClick=function(ui_element) --[[ MiDKPAnnounceFrameMemberAll:SetChecked(0) MiDKPAnnounceFrameMemberClass:SetChecked(0) MiDKPAnnounceFrameMemberArmor:SetChecked(0) MiDKP_UIHelp.General.CheckButtonListSetChecked("MiDKPAnnounceFrameMember",MIDKP_CLASS.NAME,0) MiDKP_UIHelp.General.CheckButtonListSetChecked("MiDKPAnnounceFrameMember",MIDKP_ARMOR.NAME,0)]] MiDKP_UIHelp.Util.UpdateButtonState() end, } MiDKP_UI.MemberPick={ EditBox_OnLeave=function(ui_element) GameTooltip:Hide() end, OK_OnClick=function() MiDKPMemberPickerFrame.members = {} local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPMemberPickerFrame.used_buttons) do if (MiDKP_8d0644c92128c1ff68223fd74ba63b56:GetChecked() and MiDKP_8d0644c92128c1ff68223fd74ba63b56.name) then table.insert(MiDKPMemberPickerFrame.members, MiDKP_8d0644c92128c1ff68223fd74ba63b56.name) end end if (MiDKPEventPage:IsShown()) then MiDKP_UIHelp.Event.DoUpdate() end if (MiDKPItemPage:IsShown()) then MiDKP_UIHelp.Item.DoUpdate() end if (MiDKP_UIHelp.Member.EditHandler()) then MiDKPMemberPickerFrame:Hide() MiDKP_UIHelp.Util.MainFrame_Enable(true) MiDKP_UIHelp.Notify.DeleteNotify(MiDKPMemberPickerFrame.index) if (MiDKPMemberPage:IsShown()) then MiDKP_UIHelp.Member.DoUpdate() end if (MiDKPEventPage:IsShown()) then MiDKP_UIHelp.Event.DoUpdate() end if (MiDKPItemPage:IsShown()) then MiDKP_UIHelp.Item.DoUpdate() end end end, Cancel_OnClick=function() MiDKPMemberPickerFrame.members = {} MiDKPMemberPickerFrame:Hide() MiDKP_UIHelp.Util.MainFrame_Enable(true) end, First5_OnClick=function() if (MiDKPMemberPickerFrameFirst5:GetChecked()) then MiDKPMemberPickerFrameRaid:SetChecked(0) MiDKPMemberPickerFrameAll:SetChecked(0) MiDKP_UIHelp.Member.UpdateMembers("first5",true,true) else MiDKPMemberPickerFrameFirst5:SetChecked(0) MiDKP_UIHelp.Member.UpdateMembers("first5",false,true) end end, Raid_OnClick=function() if (MiDKPMemberPickerFrameRaid:GetChecked()) then MiDKPMemberPickerFrameFirst5:SetChecked(0) MiDKPMemberPickerFrameAll:SetChecked(0) MiDKP_UIHelp.Member.UpdateMembers("raid",true,true) else MiDKPMemberPickerFrameRaid:SetChecked(0) MiDKP_UIHelp.Member.UpdateMembers("raid",false,true) end end, All_OnClick=function() if (MiDKPMemberPickerFrameAll:GetChecked()) then MiDKPMemberPickerFrameFirst5:SetChecked(0) MiDKPMemberPickerFrameRaid:SetChecked(0) MiDKP_UIHelp.Member.UpdateMembers("all",true,true) else MiDKPMemberPickerFrameAll:SetChecked(0) MiDKP_UIHelp.Member.UpdateMembers("all",false,true) end end, EditBox_OnEnter=function(ui_element) local MiDKP_e6955c64cf39bdb23dc86de1a9ec2117=MiDKP_Util:FindItemLink(ui_element:GetText()) if(not MiDKP_e6955c64cf39bdb23dc86de1a9ec2117)or (MiDKP_e6955c64cf39bdb23dc86de1a9ec2117=="") then return elseif (not GetItemInfo(MiDKP_e6955c64cf39bdb23dc86de1a9ec2117)) then return end GameTooltip:SetOwner( MiDKPMemberPickerFrame, "ANCHOR_TOPLEFT" ,10,-10) GameTooltip:SetHyperlink(MiDKP_e6955c64cf39bdb23dc86de1a9ec2117) GameTooltip:Show() end, } MiDKP_UI.Util={ CheckButton_OnClick=function(ui_element) local parent = ui_element:GetParent() if (parent.single) then if (ui_element:GetChecked()) then local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(parent.used_buttons) do if (MiDKP_8d0644c92128c1ff68223fd74ba63b56 ~= ui_element) then MiDKP_8d0644c92128c1ff68223fd74ba63b56:SetChecked(0) end end else ui_element:SetChecked(1) end end if parent.totalpoints then local member_size= MiDKP_UIHelp.Member.GetSelectedMembersSize() MiDKP_UIHelp.Member.SetAveragePoint(member_size) end end, Tab_OnClick=function(ui_element) local id = ui_element:GetID() MiDKP_UIHelp.General.TabSelectTab(id) if (id == 1) then MiDKPRaidPage:Show() MiDKPMemberPage:Hide() MiDKPEventPage:Hide() MiDKPItemPage:Hide() MiDKPOptionPage:Hide() MiDKPDKPPage:Hide() elseif (id == 2) then MiDKPRaidPage:Hide() MiDKPMemberPage:Show() MiDKPEventPage:Hide() MiDKPItemPage:Hide() MiDKPOptionPage:Hide() MiDKPDKPPage:Hide() elseif (id == 3) then MiDKPRaidPage:Hide() MiDKPMemberPage:Hide() MiDKPEventPage:Show() MiDKPItemPage:Hide() MiDKPOptionPage:Hide() MiDKPDKPPage:Hide() elseif (id == 4) then MiDKPRaidPage:Hide() MiDKPMemberPage:Hide() MiDKPEventPage:Hide() MiDKPItemPage:Show() MiDKPOptionPage:Hide() MiDKPDKPPage:Hide() elseif (id == 5) then MiDKPRaidPage:Hide() MiDKPMemberPage:Hide() MiDKPEventPage:Hide() MiDKPItemPage:Hide() MiDKPOptionPage:Show() MiDKPDKPPage:Hide() elseif (id == 6) then MiDKPRaidPage:Hide() MiDKPMemberPage:Hide() MiDKPEventPage:Hide() MiDKPItemPage:Hide() MiDKPOptionPage:Hide() MiDKPDKPPage:Show() end end, MiniButton_OnClick=function(ui_element, button) if (MiDKPMainFrame:IsShown()) then HideUIPanel(MiDKPMainFrame) else ShowUIPanel(MiDKPMainFrame) end end, MiniButton_OnUpdate=function(ui_element, elapsed) if (MiDKPMiniButton_DragFlag == 1) then local xpos,ypos = GetCursorPosition() local xmin,ymin = Minimap:GetLeft(), Minimap:GetBottom() xpos = xmin-xpos/Minimap:GetEffectiveScale()+70 ypos = ypos/Minimap:GetEffectiveScale()-ymin-70 local angle = math.deg(math.atan2(ypos,xpos)) MiDKPMiniButton:SetPoint("TOPLEFT", Minimap, "TOPLEFT", 53-(cos(angle)*81), -55+(sin(angle)*81)) end end, } MiDKP_UI.DKP={ OnDKPShow=function() getglobal("MiDKPDKPPageColumnHeader1Name"):SetText(MIDKP_TEXT_SORT_NAME) MiDKP_UIHelp.DKP.DoUpdate() end, AnnounceButton_OnClick=function(ui_element) MiDKP_Core.Raid.Announce(MiDKP_UIHelp.Util.GetAnnounceConfig()) end, ConfigButton_OnClick=function(ui_element) local MiDKP_1346009d8936868590c1d007e3efcfae=getglobal("MiDKPAnnounceFrame") MiDKPAnnounceFrameRaidChannel:SetChecked(MiDKP_1346009d8936868590c1d007e3efcfae.raidchannel or 1) MiDKPAnnounceFrameGuildChannel:SetChecked(MiDKP_1346009d8936868590c1d007e3efcfae.guildchannel or 0) MiDKPAnnounceFrameOfficerChannel:SetChecked(MiDKP_1346009d8936868590c1d007e3efcfae.officerchannel or 0) MiDKPAnnounceFramePartyChannel:SetChecked(MiDKP_1346009d8936868590c1d007e3efcfae.partychannel or 0) MiDKPAnnounceFrameEvent:SetChecked(MiDKP_1346009d8936868590c1d007e3efcfae.event or 1) MiDKPAnnounceFrameItem:SetChecked(MiDKP_1346009d8936868590c1d007e3efcfae.item or 1) MiDKPAnnounceFrameMembers:SetChecked(MiDKP_1346009d8936868590c1d007e3efcfae.members or 1) MiDKP_UIHelp.Util.SetSuites() MiDKPAnnounceFrame:Show() end, ConfigOK_OnClick=function(ui_element) local MiDKP_1346009d8936868590c1d007e3efcfae=ui_element:GetParent(); MiDKP_1346009d8936868590c1d007e3efcfae.raidchannel=MiDKPAnnounceFrameRaidChannel:GetChecked() MiDKP_1346009d8936868590c1d007e3efcfae.guildchannel=MiDKPAnnounceFrameGuildChannel:GetChecked() MiDKP_1346009d8936868590c1d007e3efcfae.officerchannel=MiDKPAnnounceFrameOfficerChannel:GetChecked() MiDKP_1346009d8936868590c1d007e3efcfae.partychannel=MiDKPAnnounceFramePartyChannel:GetChecked() MiDKP_1346009d8936868590c1d007e3efcfae.event=MiDKPAnnounceFrameEvent:GetChecked() MiDKP_1346009d8936868590c1d007e3efcfae.item=MiDKPAnnounceFrameItem:GetChecked() MiDKP_1346009d8936868590c1d007e3efcfae.members=MiDKPAnnounceFrameMembers:GetChecked() MiDKP_1346009d8936868590c1d007e3efcfae.selectedSuite=MiDKP_UIHelp.Util.GetSuites() MiDKP_Core.Raid.SetSuites(MiDKP_1346009d8936868590c1d007e3efcfae.selectedSuite) MiDKP_1346009d8936868590c1d007e3efcfae:Hide(); end, ColumnHeader_OnClick=function(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3) MiDKP_UIHelp.Util.UpdateSortStatus(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3,MiDKP_UIHelp.DKP) MiDKP_UIHelp.DKP.DoUpdate() end, SendDKPToPerson_OnClick=function() local __index = MiDKPDKPPage.index if (__index) then __index = __index - math.floor((__index-1)/MIDKP_DKP_PAGE_COUNT)*MIDKP_DKP_PAGE_COUNT local name = getglobal("MiDKPDKPPageDKP"..__index.."Name"):GetText() if name then local cached_option=MiDKP_Options["hide_whisper_reply"] MiDKP_Options["hide_whisper_reply"]=false MiDKP_Event.ChatMsgHandler(MiDKP_Options["whisper_command"],name) MiDKP_Options["hide_whisper_reply"]=cached_option end end end, SendDKPToParty_OnClick=function() local __index = MiDKPDKPPage.index local MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3 if MiDKPDKPPage.showtype==0 then local raid = MiDKP_Core.Raid.GetCurrentRaid(); MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3=raid.dkp else MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3=MiDKP_Core.Util.DataGetRaidByIndex(MiDKPDKPPage.showtype).name end if (__index) then __index = __index - math.floor((__index-1)/MIDKP_DKP_PAGE_COUNT)*MIDKP_DKP_PAGE_COUNT local name = getglobal("MiDKPDKPPageDKP"..__index.."Name"):GetText() local total = getglobal("MiDKPDKPPageDKP"..__index.."Bonus"):GetText() local point = getglobal("MiDKPDKPPageDKP"..__index.."TotalBonus"):GetText() if name then MiDKP_Core.Member.SendMemberPoint(name,point,total,"party",MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3) end end end, SendDKPToRaid_OnClick=function() local __index = MiDKPDKPPage.index local MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3 if MiDKPDKPPage.showtype==0 then local raid = MiDKP_Core.Raid.GetCurrentRaid(); MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3=raid.dkp else MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3=MiDKP_Core.Util.DataGetRaidByIndex(MiDKPDKPPage.showtype).name end if (__index) then __index = __index - math.floor((__index-1)/MIDKP_DKP_PAGE_COUNT)*MIDKP_DKP_PAGE_COUNT local name = getglobal("MiDKPDKPPageDKP"..__index.."Name"):GetText() local total = getglobal("MiDKPDKPPageDKP"..__index.."Bonus"):GetText() local point = getglobal("MiDKPDKPPageDKP"..__index.."TotalBonus"):GetText() if name then MiDKP_Core.Member.SendMemberPoint(name,point,total,"raid",MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3) end end end, SendDKPToGuild_OnClick=function() local __index = MiDKPDKPPage.index local MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3 if MiDKPDKPPage.showtype==0 then local raid = MiDKP_Core.Raid.GetCurrentRaid(); MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3=raid.dkp else MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3=MiDKP_Core.Util.DataGetRaidByIndex(MiDKPDKPPage.showtype).name end if (__index) then __index = __index - math.floor((__index-1)/MIDKP_DKP_PAGE_COUNT)*MIDKP_DKP_PAGE_COUNT local name = getglobal("MiDKPDKPPageDKP"..__index.."Name"):GetText() local total = getglobal("MiDKPDKPPageDKP"..__index.."Bonus"):GetText() or "" local point = getglobal("MiDKPDKPPageDKP"..__index.."TotalBonus"):GetText() or "" if name then MiDKP_Core.Member.SendMemberPoint(name,point,total,"guild",MiDKP_b7fef6e7e0c091ae62ea7c2b267c03c3) end end end, } MiDKP_UIHelp={} MiDKP_UIHelp.Event={ MiDKP_5872af8c53c19a2665ed9942c461d8e5=function() local page = MiDKPEventPage.page or 1; local raid = MiDKP_Core.Raid.GetCurrentRaid(); if (not raid) then MiDKPEventPageCreate:Disable(); MiDKPEventPageDelete:Disable(); MiDKPEventPageModify:Disable(); MiDKPEventPagePrevButton:Disable(); MiDKPEventPageNextButton:Disable(); return; end MiDKPEventPageCreate:Enable(); if (raid["start"]) then MiDKPEventPageCreate:Enable(); if (MiDKPEventPage.index) and (MiDKPEventPage.index > (page - 1)*MIDKP_EVENT_PAGE_COUNT) then MiDKPEventPageModify:Enable(); MiDKPEventPageDelete:Enable(); else MiDKPEventPageModify:Disable(); MiDKPEventPageDelete:Disable(); end else MiDKPEventPageCreate:Disable(); MiDKPEventPageModify:Disable(); MiDKPEventPageDelete:Disable(); end local i; MiDKP_Widget.Panel().ListPanel("Event",MIDKP_EVENT_PAGE_COUNT).UpdateButtons() MiDKP_Widget.Button(MiDKPEventPagePrevButton).PrevButton().SetEnable() MiDKP_Widget.Button(MiDKPEventPageNextButton).NextButton(MIDKP_EVENT_PAGE_COUNT,MiDKP_Core.Util.GetEventCount).SetEnable() end, MiDKP_41f2475775117e83c0ed3795fd289f00=function(index) local id = MiDKP_Core.Util.GetID("event", index); if (id) then MiDKP_Core.Raid.ModifyEvent(index, nil, nil, MiDKPMemberPickerFrame.members); MiDKP_UIHelp.Event.DoUpdate(); end end, GetEventButton=function(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3) local MiDKP_e914904fab9d05d3f54d52bfc31a0f3f = 1; local MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = getglobal("MiDKPNotifyEventButton"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f); local MiDKP_55d037560a41a22989e2d25ae19c6c36=function(MiDKP_9248008bbb6d0ee7ce13f6ee45680051,left,right,top,bottom) MiDKP_9248008bbb6d0ee7ce13f6ee45680051:SetTexCoord(left,right,top,bottom) MiDKP_9248008bbb6d0ee7ce13f6ee45680051:SetWidth(128) MiDKP_9248008bbb6d0ee7ce13f6ee45680051:SetHeight(128) end local MiDKP_811e923cca5a86d49d147acb090aade1=function(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5,MiDKP_c3a659eeaf5bb2bc220c9161451b1e84) local MiDKP_97b0611ff944b8e22aa1ddf0c73b49e3="Interface\\AddOns\\MiDKP\\"..string.lower(MiDKP_c3a659eeaf5bb2bc220c9161451b1e84).."_notify" MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetNormalTexture(MiDKP_97b0611ff944b8e22aa1ddf0c73b49e3) MiDKP_55d037560a41a22989e2d25ae19c6c36(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:GetNormalTexture(),0.5,1,0,0.5) MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetPushedTexture(MiDKP_97b0611ff944b8e22aa1ddf0c73b49e3) MiDKP_55d037560a41a22989e2d25ae19c6c36(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:GetPushedTexture(),0,0.5,0,0.5) MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetDisabledTexture(MiDKP_97b0611ff944b8e22aa1ddf0c73b49e3) MiDKP_55d037560a41a22989e2d25ae19c6c36(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:GetDisabledTexture(),0,0.5,0.5,1) MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetHighlightTexture(MiDKP_97b0611ff944b8e22aa1ddf0c73b49e3) MiDKP_55d037560a41a22989e2d25ae19c6c36(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:GetHighlightTexture(),0.5,1,0,0.5) local MiDKP_94e1ab5d3cefd13c13ae38b9397161b0=getglobal(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:GetName().."Glow") MiDKP_94e1ab5d3cefd13c13ae38b9397161b0:SetTexture(MiDKP_97b0611ff944b8e22aa1ddf0c73b49e3) MiDKP_55d037560a41a22989e2d25ae19c6c36(MiDKP_94e1ab5d3cefd13c13ae38b9397161b0,0.5,1,0.5,1) end while (MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5) do if (not MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:IsVisible()) then MiDKP_811e923cca5a86d49d147acb090aade1(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5,MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3) return MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5; end MiDKP_e914904fab9d05d3f54d52bfc31a0f3f = MiDKP_e914904fab9d05d3f54d52bfc31a0f3f + 1; MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = getglobal("MiDKPNotifyEventButton" .. MiDKP_e914904fab9d05d3f54d52bfc31a0f3f); end MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = CreateFrame("Button", "MiDKPNotifyEventButton"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f, UIParent, "MiDKPNotifyButtonTemplate"); MiDKP_811e923cca5a86d49d147acb090aade1(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5,MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3) return MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5; end, SetEventButtonList=function(MiDKP_e0744a0bff1e34800f14ca9a06b32530) MiDKP_Widget.Panel().SetButtons(MiDKP_e0744a0bff1e34800f14ca9a06b32530,"Event") end, GetEventFrame=function() if(not MiDKP_EventFrame)then MiDKP_EventFrame=CreateFrame("Button", "MiDKPNotifyEventFrame", UIParent, "MiDKPEventFrameTemplate"); MiDKP_EventFrame:SetPoint("BOTTOMRIGHT", UIParent, "BOTTOMRIGHT", -350, 120); end end, DoUpdate=function() local raid = MiDKP_Core.Raid.GetCurrentRaid(); local MiDKP_e0744a0bff1e34800f14ca9a06b32530={} if (raid and raid["events"]) then MiDKP_e0744a0bff1e34800f14ca9a06b32530=MiDKP_Core.Util.GetEventsByPage(raid,MiDKPEventPage.page or 1) end MiDKP_UIHelp.Event.SetEventButtonList(MiDKP_e0744a0bff1e34800f14ca9a06b32530) MiDKP_UIHelp.Event.MiDKP_5872af8c53c19a2665ed9942c461d8e5(); end, } MiDKP_UIHelp.General={ CheckButtonListEnable=function(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a,MiDKP_e5e6de68d2a1aaafcf13014c54794791) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_e5e6de68d2a1aaafcf13014c54794791) do MiDKP_UIHelp.General.CheckButtonEnable(getglobal(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a..MiDKP_8d0644c92128c1ff68223fd74ba63b56)); end end, CheckButtonListDisable=function(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a,MiDKP_e5e6de68d2a1aaafcf13014c54794791) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_e5e6de68d2a1aaafcf13014c54794791) do MiDKP_UIHelp.General.CheckButtonDisable(getglobal(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a..MiDKP_8d0644c92128c1ff68223fd74ba63b56)); end end, CheckButtonListGetCheck=function(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a,MiDKP_e5e6de68d2a1aaafcf13014c54794791) local member={} for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_e5e6de68d2a1aaafcf13014c54794791) do if(getglobal(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a..MiDKP_8d0644c92128c1ff68223fd74ba63b56):GetChecked()) then member[string.upper(MiDKP_8d0644c92128c1ff68223fd74ba63b56)]=true; end end return member; end, CheckButtonListSetVerColor=function(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a,MiDKP_e5e6de68d2a1aaafcf13014c54794791,...) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_e5e6de68d2a1aaafcf13014c54794791) do getglobal(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a..MiDKP_8d0644c92128c1ff68223fd74ba63b56):SetVertexColor(...); end end, CheckButtonListShow=function(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a,MiDKP_e5e6de68d2a1aaafcf13014c54794791) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_e5e6de68d2a1aaafcf13014c54794791) do getglobal(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a..MiDKP_8d0644c92128c1ff68223fd74ba63b56):Show(); end end, CheckButtonListHide=function(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a,MiDKP_e5e6de68d2a1aaafcf13014c54794791) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_e5e6de68d2a1aaafcf13014c54794791) do getglobal(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a..MiDKP_8d0644c92128c1ff68223fd74ba63b56):Hide(); end end, CheckButtonListSetChecked=function(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a,MiDKP_e5e6de68d2a1aaafcf13014c54794791,...) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_e5e6de68d2a1aaafcf13014c54794791) do getglobal(MiDKP_411b8aa6d5954c6020f0b9c9e80e847a..MiDKP_8d0644c92128c1ff68223fd74ba63b56):SetChecked(...); end end, TabSelectTab=function(index) local i; for i = 1, 6, 1 do if (i == index) then MiDKP_UIHelp.General.tabSetLayout(getglobal("MiDKPMainFrameTab"..i), "raise"); else MiDKP_UIHelp.General.tabSetLayout(getglobal("MiDKPMainFrameTab"..i), "lower"); end end end, CheckButtonEnable=function(button) button:Enable() getglobal(button:GetName().."Text"):SetTextColor(1.0, 0.82, 0.0); button.disabled = nil; end, CheckButtonDisable=function(button) button:Disable() getglobal(button:GetName().."Text"):SetTextColor(0.5, 0.5, 0.5); button.disabled = true; end, tabSetLayout=function(tab,layout) local left = getglobal(tab:GetName().."Left"); local right = getglobal(tab:GetName().."Right"); local center = getglobal(tab:GetName().."Center"); local back = getglobal(tab:GetName().."Background"); local text = getglobal(tab:GetName().."Text"); if (layout == "raise") then tab:SetHeight(50); left:SetWidth(18); left:SetHeight(50); left:SetTexCoord(0.25390625, 0.3203125, 0.28515625, 0.4765625); right:SetWidth(13); right:SetHeight(50); right:SetTexCoord(0.49609375, 0.54296875, 0.28515625, 0.4765625); center:SetWidth(44); center:SetHeight(50); center:SetTexCoord(0.32421875, 0.4921875, 0.28515625, 0.4765625); back:ClearAllPoints(); back:SetPoint("TOPLEFT", left, "TOPLEFT", 9, 2); back:SetPoint("BOTTOMRIGHT", right, "BOTTOMRIGHT", -4, 9); text:SetPoint("CENTER", tab, "CENTER", 2, 0); local id = tab:GetID(); if (id == 1) then tab:SetPoint("BOTTOMLEFT", tab:GetParent(), "BOTTOMLEFT", 20, -24); else local last_id = id - 1; local last_tab = getglobal(tab:GetParent():GetName().."Tab"..last_id); if (last_tab) then if (last_tab.raise) then tab:ClearAllPoints(); tab:SetPoint("BOTTOMLEFT", last_tab, "BOTTOMRIGHT", 0, 0); else tab:ClearAllPoints(); tab:SetPoint("BOTTOMLEFT", last_tab, "BOTTOMRIGHT", 0, -2); end end end tab.raise = true; elseif (layout == "lower") then tab:SetHeight(31); left:SetWidth(19); left:SetHeight(31); left:SetTexCoord(0.69921875, 0.76953125, 0.87890625, 0.99609375); right:SetWidth(14); right:SetHeight(31); right:SetTexCoord(0.94140625, 0.9921875, 0.87890625, 0.99609375); center:SetWidth(43); center:SetHeight(31); center:SetTexCoord(0.7734375, 0.9375, 0.87890625, 0.99609375); back:ClearAllPoints(); back:SetPoint("TOPLEFT", left, "TOPLEFT", 11, 0); back:SetPoint("BOTTOMRIGHT", right, "BOTTOMRIGHT", -6, 10); text:SetPoint("CENTER", tab, "CENTER", 2, 5); local id = tab:GetID(); if (id == 1) then tab:ClearAllPoints(); tab:SetPoint("BOTTOMLEFT", tab:GetParent(), "BOTTOMLEFT", 20, -22); else local last_id = id - 1; local last_tab = getglobal(tab:GetParent():GetName().."Tab"..last_id); if (last_tab) then if (last_tab.raise) then tab:ClearAllPoints(); tab:SetPoint("BOTTOMLEFT", last_tab, "BOTTOMRIGHT", 0, 2); else tab:ClearAllPoints(); tab:SetPoint("BOTTOMLEFT", last_tab, "BOTTOMRIGHT", 0, 0); end end end tab.raise = nil; end end, ShowEditPage=function(MiDKP_e78d229014c7a07be65fde4797b92c86, index, MiDKP_f9542af0fc240db769f6a4369804f562, MiDKP_e6955c64cf39bdb23dc86de1a9ec2117, MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7, MiDKP_4e38a5d83009d7f7e9f5a7db6b2655b8,MiDKP_2fa468158e8ccca35651477aab291193,MiDKP_984dfc5857625dc9e372678117f1e594,MiDKP_ada8874fb69bfe1c97ae6bff9e60a2ff,MiDKP_4a6d6eef387c094fb863f5a9e73ea6d0) local MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351 MiDKP_UIHelp.Util.MainFrame_Enable(false); MiDKPMemberPickerFrame:Show(); MiDKPMemberPickerFrameFirst5:SetChecked(0); MiDKPMemberPickerFrameRaid:SetChecked(0); MiDKPMemberPickerFrameAll:SetChecked(0); local MiDKP_9caaf8d40fae5eebbd51771e96608617=MiDKP_Config["running_raid"] if (MiDKP_4e38a5d83009d7f7e9f5a7db6b2655b8) then MiDKP_UIHelp.General.CheckButtonDisable(MiDKPMemberPickerFrameFirst5); MiDKP_UIHelp.General.CheckButtonDisable(MiDKPMemberPickerFrameRaid); MiDKP_UIHelp.General.CheckButtonDisable(MiDKPMemberPickerFrameAll); else MiDKP_UIHelp.General.CheckButtonEnable(MiDKPMemberPickerFrameFirst5); MiDKP_UIHelp.General.CheckButtonEnable(MiDKPMemberPickerFrameRaid); MiDKP_UIHelp.General.CheckButtonEnable(MiDKPMemberPickerFrameAll); end if (not MiDKP_9caaf8d40fae5eebbd51771e96608617)then MiDKP_UIHelp.General.CheckButtonDisable(MiDKPMemberPickerFrameFirst5); MiDKP_UIHelp.General.CheckButtonDisable(MiDKPMemberPickerFrameRaid); end MiDKPMemberPickerFrame.category = MiDKP_e78d229014c7a07be65fde4797b92c86; MiDKPMemberPickerFrame.members = MiDKP_f9542af0fc240db769f6a4369804f562; MiDKPMemberPickerFrame.text = MiDKP_e6955c64cf39bdb23dc86de1a9ec2117; MiDKPMemberPickerFrame.point = MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7; MiDKPMemberPickerFrame.index = index; MiDKPMemberPickerFrame.single = MiDKP_4e38a5d83009d7f7e9f5a7db6b2655b8; MiDKPMemberPickerFrame.isevent = MiDKP_984dfc5857625dc9e372678117f1e594; MiDKPMemberPickerFrame.totalpoints=nil if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "event") then if MiDKP_4a6d6eef387c094fb863f5a9e73ea6d0 then MiDKPMemberPickerFrame.totalpoints=MiDKP_Core.Item.GetItemById(MiDKP_4a6d6eef387c094fb863f5a9e73ea6d0).point end if (index) then MiDKPMemberPickerFrameHeader:SetText(MIDKP_TEXT_MODIFY_EVENT); else MiDKPMemberPickerFrameHeader:SetText(MIDKP_TEXT_ADD_EVENT); end getglobal("MiDKPMemberPickerFrameBossEvent"):Show() if (MiDKP_984dfc5857625dc9e372678117f1e594) then getglobal("MiDKPMemberPickerFrameBossEvent"):Disable() else getglobal("MiDKPMemberPickerFrameBossEvent"):Enable() end if (MiDKP_Options["default_member_filter"] == "first5" and MiDKP_984dfc5857625dc9e372678117f1e594 and MiDKP_ada8874fb69bfe1c97ae6bff9e60a2ff) then MiDKPMemberPickerFrameFirst5:SetChecked(1) MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351= "first5" elseif (MiDKP_Options["default_member_filter"] == "raid" and MiDKP_984dfc5857625dc9e372678117f1e594 and MiDKP_ada8874fb69bfe1c97ae6bff9e60a2ff) then MiDKPMemberPickerFrameRaid:SetChecked(1) MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351= "raid" elseif (MiDKP_Options["default_member_filter"] == "all" and MiDKP_984dfc5857625dc9e372678117f1e594 and MiDKP_ada8874fb69bfe1c97ae6bff9e60a2ff) then MiDKPMemberPickerFrameAll:SetChecked(1) MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351= "all" end if MiDKP_2fa468158e8ccca35651477aab291193 then getglobal("MiDKPMemberPickerFrameBossEvent"):SetChecked(1) else getglobal("MiDKPMemberPickerFrameBossEvent"):SetChecked(0) end _G["MiDKPMemberPickerFrameSplitPoints"]:Hide() else getglobal("MiDKPMemberPickerFrameBossEvent"):Hide() if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "item") then if (index) then MiDKPMemberPickerFrameHeader:SetText(MIDKP_TEXT_MODIFY_ITEM); else MiDKPMemberPickerFrameHeader:SetText(MIDKP_TEXT_ADD_ITEM); end _G["MiDKPMemberPickerFrameSplitPoints"]:Show() if MiDKP_4a6d6eef387c094fb863f5a9e73ea6d0 then _G["MiDKPMemberPickerFrameSplitPoints"]:SetChecked(1) else _G["MiDKPMemberPickerFrameSplitPoints"]:SetChecked(0) end end if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "member") then if (index) then MiDKPMemberPickerFrameHeader:SetText(MIDKP_TEXT_MODIFY_EVENT); else MiDKPMemberPickerFrameHeader:SetText(MIDKP_TEXT_ADD_EVENT); end _G["MiDKPMemberPickerFrameSplitPoints"]:Hide() end end MiDKP_UIHelp.Member.UpdateMembers(MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351); end, } MiDKP_UIHelp.Raid={ DoUpdate=function() local index = 1; if (MiDKP_Config.raids) then local page = MiDKPRaidPage.page or 1; local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56; local start = (page - 1) * MIDKP_RAID_PAGE_COUNT + 1; for MiDKP_63a9ce6f1eeac72ef41293b7d0303335 = start, start + MIDKP_RAID_PAGE_COUNT - 1, 1 do local id = MiDKP_Core.Util.GetID("raid", MiDKP_63a9ce6f1eeac72ef41293b7d0303335); MiDKP_8d0644c92128c1ff68223fd74ba63b56 = MiDKP_Config.raids[id]; if (MiDKP_8d0644c92128c1ff68223fd74ba63b56) then if (not MiDKPRaidPage.index) then if (MiDKP_Config_Wrapper:IsIdMatchCurrent(id)) then MiDKPRaidPage.index = MiDKP_63a9ce6f1eeac72ef41293b7d0303335; end end MiDKP_UIHelp.Raid.ShowRaidCellButton(getglobal("MiDKPRaidPageRaid"..index),MiDKP_8d0644c92128c1ff68223fd74ba63b56) index = index + 1; end end end local i; for i = index, MIDKP_RAID_PAGE_COUNT, 1 do local button = getglobal("MiDKPRaidPageRaid"..i); button:Hide(); end MiDKP_UIHelp.Raid.MiDKP_5872af8c53c19a2665ed9942c461d8e5(); end, MiDKP_4867552ae1ccce65c18e3966b071d6d7=function() MiDKPRaidPageDelete:Disable(); MiDKPRaidPageModify:Disable(); MiDKPRaidPageAction:Disable(); end, MiDKP_5872af8c53c19a2665ed9942c461d8e5=function() local page = MiDKPRaidPage.page or 1; if (MiDKPRaidPage.index) then if (MiDKPRaidPage.index > (page - 1)*MIDKP_RAID_PAGE_COUNT) then MiDKPRaidPageDelete:Enable(); MiDKPRaidPageModify:Enable(); local id = MiDKP_Core.Util.GetID("raid", MiDKPRaidPage.index); if (id) then if (MiDKP_Config["raids"][id]["end"]) then MiDKPRaidPageAction:SetText(MIDKP_TEXT_RAID_EXPORT); MiDKPRaidPageAction:Enable(); elseif (MiDKP_Config["raids"][id]["start"]) then MiDKPRaidPageAction:SetText(MIDKP_TEXT_RAID_END); MiDKPRaidPageAction:Enable(); else MiDKPRaidPageAction:SetText(MIDKP_TEXT_RAID_START); MiDKPRaidPageAction:Enable(); end else MiDKPRaidPageAction:Disable(); end else MiDKP_UIHelp.Raid.MiDKP_4867552ae1ccce65c18e3966b071d6d7(); end else MiDKP_UIHelp.Raid.MiDKP_4867552ae1ccce65c18e3966b071d6d7(); end local i for i = 1, MIDKP_RAID_PAGE_COUNT, 1 do local __index = (page - 1) * MIDKP_RAID_PAGE_COUNT + i; local button = getglobal("MiDKPRaidPageRaid"..i); MiDKP_UIHelp.Raid.RaidButton_Update(button,__index); end MiDKP_Widget.Button(MiDKPRaidPagePrevButton).PrevButton().SetEnable() MiDKP_Widget.Button(MiDKPRaidPageNextButton).NextButton(MIDKP_RAID_PAGE_COUNT,MiDKP_Core.Util.GetRaidCount).SetEnable() end, ResetRaidPages=function() MiDKPEventPage.index = nil; MiDKPItemPage.index = nil; MiDKPMemberPage.index = nil; end, GetDKPSetButton=function() if (MiDKPRaidEditFrame.unused_buttons[1]) then local button = MiDKPRaidEditFrame.unused_buttons[1]; table.remove(MiDKPRaidEditFrame.unused_buttons, 1); table.insert(MiDKPRaidEditFrame.used_buttons, button); return button; end local name = "MiDKPRaidEditFrameDKP"..(MiDKPRaidEditFrame.button_count + 1); local button = CreateFrame("CheckButton", name, MiDKPRaidEditFrame, "MiDKPCheckButtonTemplate"); button:SetScript("OnClick", MiDKP_UI.Util.CheckButton_OnClick); button:SetWidth(150); button:SetHeight(36); table.insert(MiDKPRaidEditFrame.used_buttons, button); MiDKPRaidEditFrame.button_count = MiDKPRaidEditFrame.button_count + 1; return button; end, ResetDKPSetButtons=function() local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56; for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPRaidEditFrame.used_buttons) do table.insert(MiDKPRaidEditFrame.unused_buttons, MiDKP_8d0644c92128c1ff68223fd74ba63b56); end MiDKPRaidEditFrame.used_buttons = {} end, ShowRaidEditFrame=function(index) local left = 10; local top = -10; local set = {} local MiDKP_8d0febf2348ea712b2b375ae95601d5f; local MiDKP_8983c60d66c8593ec7165ea9dbedb584; local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56; if (MiDKPData and MiDKPData["dkp"]) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPData["dkp"]) do table.insert(set, MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"]); end end; if (index) then MiDKPRaidEditFrameHeader:SetText(MIDKP_TEXT_MODIFY_RAID); MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Util.GetID("raid", index); MiDKP_8983c60d66c8593ec7165ea9dbedb584 = MiDKP_Config["raids"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["name"]; if (MiDKP_8d0febf2348ea712b2b375ae95601d5f) then MiDKPRaidEditFrame.id = MiDKP_8d0febf2348ea712b2b375ae95601d5f; else MiDKPRaidEditFrame.id = nil; end else MiDKPRaidEditFrameHeader:SetText(MIDKP_TEXT_CREATE_RAID); local time = MiDKP_Util:GetTimeStamp(); MiDKP_8983c60d66c8593ec7165ea9dbedb584 = MIDKP_TEXT_RAID_PATTERN .. time[1] .. ")"; MiDKPRaidEditFrame.id = nil; end if (MiDKP_8983c60d66c8593ec7165ea9dbedb584) then MiDKPRaidEditFrameText:SetText(MiDKP_8983c60d66c8593ec7165ea9dbedb584); MiDKPRaidEditFrameText:SetFocus(); MiDKPRaidEditFrameText:HighlightText(); else MiDKPRaidEditFrameText:SetText(""); MiDKPRaidEditFrameText:SetFocus(); end local lines = 1; local MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = 0; local MiDKP_c691cd64eb1bfe6a6d3ac85cdf86bf7c; MiDKP_UIHelp.Raid.ResetDKPSetButtons(); if (set) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(set) do local button = MiDKP_UIHelp.Raid.GetDKPSetButton(); local text = MiDKP_8d0644c92128c1ff68223fd74ba63b56; button.text = MiDKP_8d0644c92128c1ff68223fd74ba63b56; left,top,lines=MiDKP_Util:CalculateCoord(left,top,lines); button:SetPoint("TOPLEFT", MiDKPRaidEditFrameInnerFrame, "TOPLEFT", left, top); getglobal(button:GetName().."Text"):SetText(text); button.text = text; if (not MiDKP_c691cd64eb1bfe6a6d3ac85cdf86bf7c) then MiDKP_c691cd64eb1bfe6a6d3ac85cdf86bf7c = button; end if (MiDKP_8d0febf2348ea712b2b375ae95601d5f and MiDKP_Config["raids"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["dkp"] and MiDKP_Config["raids"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["dkp"] == MiDKP_8d0644c92128c1ff68223fd74ba63b56) then MiDKP_c691cd64eb1bfe6a6d3ac85cdf86bf7c = button; end button:SetChecked(0); left = left + 180; button:Show(); MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_3f50417fb16be9b1078eb68d24fa9c26 + 1; end if (MiDKP_c691cd64eb1bfe6a6d3ac85cdf86bf7c) then MiDKP_c691cd64eb1bfe6a6d3ac85cdf86bf7c:SetChecked(1); end end MiDKPRaidEditFrame:SetWidth(600); MiDKPRaidEditFrame:SetHeight(270 + lines * 24); if (MiDKP_3f50417fb16be9b1078eb68d24fa9c26 > 0) then MiDKPRaidEditFrame:SetWidth(600); MiDKPRaidEditFrame:SetHeight(205 + lines * 24); MiDKPRaidEditFrameSetHeader:Show(); MiDKPRaidEditFrameInnerFrame:SetHeight(30 + lines * 24); MiDKPRaidEditFrameInnerFrame:Show(); else MiDKPRaidEditFrame:SetWidth(600); MiDKPRaidEditFrame:SetHeight(180); MiDKPRaidEditFrameSetHeader:Hide(); MiDKPRaidEditFrameInnerFrame:Hide(); end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPRaidEditFrame.unused_buttons) do MiDKP_8d0644c92128c1ff68223fd74ba63b56:Hide(); MiDKP_8d0644c92128c1ff68223fd74ba63b56:SetChecked(0); end MiDKPRaidEditFrame:Show(); end, ShowRaidCellButton=function(ui_element,MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af) ui_element:Show(); getglobal(ui_element:GetName().."Name"):SetText(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["name"]); if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["dkp"]) then getglobal(ui_element:GetName().."DKP"):SetText(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["dkp"]); else getglobal(ui_element:GetName().."DKP"):SetText(""); end getglobal(ui_element:GetName().."Places"):SetText(MiDKP_Util:JoinString(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["places"])); local status = ""; if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["start"] and not MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["end"]) then status = MIDKP_TEXT_RAID_RUNNING; elseif (not MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["start"]) then status = MIDKP_TEXT_RAID_STATUS_NO_START; elseif (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["start"] and MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["end"]) then status = MIDKP_TEXT_RAID_STATUS_END; end getglobal(ui_element:GetName().."Status"):SetText(status); local info = ""; local MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = 0; local MiDKP_b346ff9c8a9ef882088b9f1c82dabf17, MiDKP_1f767451a35d2d22ad352ee7ff068312; if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"]) then for MiDKP_b346ff9c8a9ef882088b9f1c82dabf17, MiDKP_1f767451a35d2d22ad352ee7ff068312 in pairs(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"]) do MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_3f50417fb16be9b1078eb68d24fa9c26 + 1; end end info = info .. string.format(MIDKP_TEXT_RAID_TOTAL_MEMBER, MiDKP_3f50417fb16be9b1078eb68d24fa9c26); if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["start"]) then info = info .. string.format(MIDKP_TEXT_RAID_START_TIME, MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["start"]["time"] and MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["start"]["time"][1] or ""); if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["end"]) then info = info .. string.format(MIDKP_TEXT_RAID_END_TIME, MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["end"]["time"] and MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["end"]["time"][1] or ""); end end getglobal(ui_element:GetName().."Info"):SetText(info); end, RaidButton_Update=function(ui_element) MiDKP_Widget.Button(ui_element).ListButton(MIDKP_RAID_PAGE_COUNT,50,65,"Info","Status").Update() local __index = ((MiDKPRaidPage.page or 1) - 1) * MIDKP_RAID_PAGE_COUNT + ui_element:GetID(); local MiDKP_1346009d8936868590c1d007e3efcfae = ui_element:GetParent(); if (__index == MiDKP_1346009d8936868590c1d007e3efcfae.index) then getglobal(ui_element:GetName().."ActiveButton"):SetText(MIDKP_TEXT_ACTIVE); getglobal(ui_element:GetName().."ActiveButton"):Show(); local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Util.GetID("raid",__index); if (MiDKP_Config_Wrapper:IsIdMatchCurrent(MiDKP_8d0febf2348ea712b2b375ae95601d5f)) then getglobal(ui_element:GetName().."ActiveButton"):Disable(); else getglobal(ui_element:GetName().."ActiveButton"):Enable(); end else getglobal(ui_element:GetName().."ActiveButton"):Hide(); end if (MouseIsOver(ui_element)) then local nameob = getglobal(ui_element:GetName().."Name"); nameob:SetTextColor(1.0, 1.0, 1.0); else local MiDKP_8d0febf2348ea712b2b375ae95601d5f = MiDKP_Core.Util.GetID("raid", __index); if (MiDKP_8d0febf2348ea712b2b375ae95601d5f) then local nameob = getglobal(ui_element:GetName().."Name"); if (MiDKP_Config_Wrapper:IsIdMatchCurrent(MiDKP_8d0febf2348ea712b2b375ae95601d5f)) then nameob:SetTextColor(0.0, 1.0, 1.0); else nameob:SetTextColor(NORMAL_FONT_COLOR.r, NORMAL_FONT_COLOR.g, NORMAL_FONT_COLOR.b); end end end end, } MiDKP_UIHelp.Member={ sortby={ name="asc", class="asc", dkp="asc", totaldkp="asc", }, status={}, currentsort="name", classfilter={}, DropDownClassInit=function() MiDKP_Widget.DDList(MiDKP_UIHelp.Member.DoUpdate,MiDKP_UIHelp.Member.classfilter,MiDKP_UIHelp.Member.status,MiDKPMemberPage).Class().DropDownInit() end, EditHandler=function() local MiDKP_c6c556b8f78fbb66eef4745eb204996d=function() local MiDKP_f9542af0fc240db769f6a4369804f562 = {} local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56; for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPMemberPickerFrame.used_buttons) do if (MiDKP_8d0644c92128c1ff68223fd74ba63b56:GetChecked() and MiDKP_8d0644c92128c1ff68223fd74ba63b56.name) then table.insert(MiDKP_f9542af0fc240db769f6a4369804f562, MiDKP_8d0644c92128c1ff68223fd74ba63b56.name); end end return MiDKP_f9542af0fc240db769f6a4369804f562; end local MiDKP_3a1dd5492cf8b0ead9992a6b06e1e845=function() local MiDKP_8983c60d66c8593ec7165ea9dbedb584 = MiDKPMemberPickerFrameText:GetText(); if (MiDKP_8983c60d66c8593ec7165ea9dbedb584 == "") then return end return MiDKP_8983c60d66c8593ec7165ea9dbedb584 end local MiDKP_c03e04bc6c680c1806f97150be45ac04=function() local MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7 = MiDKPMemberPickerFramePoint:GetText(); MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7 = MiDKP_Util:GetPoint(MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7); if (not MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7) then return false; end if abs(MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7) >100000 then return false end return MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7 end local MiDKP_8983c60d66c8593ec7165ea9dbedb584=MiDKP_3a1dd5492cf8b0ead9992a6b06e1e845() local MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7=MiDKP_c03e04bc6c680c1806f97150be45ac04() if not MiDKP_8983c60d66c8593ec7165ea9dbedb584 then MiDKP_Util:Print("error",MIDKP_TEXT_INVALID_EVENT); return false end if not MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7 then MiDKP_Util:Print("error",MIDKP_TEXT_INVALID_POINT); return false end if MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7<0 then if (MiDKPMemberPickerFrame.category == "event" and MiDKPMemberPickerFrameBossEvent:GetChecked()==1) then MiDKP_Util:Print("error",MIDKP_TEXT_INVALID_POINT); return false elseif MiDKPMemberPickerFrame.category == "item" then MiDKP_Util:Print("error",MIDKP_TEXT_INVALID_POINT); return false end end local MiDKP_f9542af0fc240db769f6a4369804f562 =MiDKP_c6c556b8f78fbb66eef4745eb204996d(); if not MiDKP_Util:IsTableNotEmpty(MiDKP_f9542af0fc240db769f6a4369804f562) then MiDKP_Util:Print("error",MIDKP_TEXT_EVENT_EMPTY_MEMBERS); return false end if (MiDKPMemberPickerFrame.category == "event") then if (not MiDKPMemberPickerFrame.index) then return MiDKP_Core.Raid.CreateEvent(MiDKP_8983c60d66c8593ec7165ea9dbedb584, MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7, MiDKP_f9542af0fc240db769f6a4369804f562,MiDKPMemberPickerFrameBossEvent:GetChecked(),MiDKPMemberPickerFrame.isevent ); else return MiDKP_Core.Raid.ModifyEvent(MiDKPMemberPickerFrame.index, MiDKP_8983c60d66c8593ec7165ea9dbedb584, MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7, MiDKP_f9542af0fc240db769f6a4369804f562,MiDKPMemberPickerFrameBossEvent:GetChecked(),MiDKPMemberPickerFrame.isevent); end elseif (MiDKPMemberPickerFrame.category == "item") then if (not MiDKPMemberPickerFrame.index) then return MiDKP_Core.Item.CreateItem(MiDKP_8983c60d66c8593ec7165ea9dbedb584, abs(MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7), MiDKP_f9542af0fc240db769f6a4369804f562,MiDKPMemberPickerFrameSplitPoints:GetChecked()); else return MiDKP_Core.Item.ModifyItem(MiDKPMemberPickerFrame.index, MiDKP_8983c60d66c8593ec7165ea9dbedb584, abs(MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7), MiDKP_f9542af0fc240db769f6a4369804f562,MiDKPMemberPickerFrameSplitPoints:GetChecked()); end else if (not MiDKPMemberPickerFrame.index) then return MiDKP_Core.Raid.CreateEvent(MiDKP_8983c60d66c8593ec7165ea9dbedb584, MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7, MiDKP_f9542af0fc240db769f6a4369804f562,MiDKPMemberPickerFrame.boss); else return MiDKP_Core.Raid.ModifyEvent(MiDKPMemberPickerFrame.index, MiDKP_8983c60d66c8593ec7165ea9dbedb584, MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7, MiDKP_f9542af0fc240db769f6a4369804f562,MiDKPMemberPickerFrame.boss); end end return false; end, ToggleBoss=function(ui_element) if (ui_element:GetChecked()) then MiDKPMemberPickerFrame.boss=MiDKPMemberPickerFrameText:GetText(); else MiDKPMemberPickerFrame.boss=nil; end end, UpdateMembers=function(MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351,MiDKP_30b6f278098f3fa7bf562ea6d5620a66,MiDKP_befe792f41e009c2804d4d8f78109f9e) local raid = MiDKP_Core.Raid.GetCurrentRaid(); if not raid then MiDKP_Util:Print("error", MIDKP_TEXT_NO_IN_RAID) return end local MiDKP_830674a0d2d9035ecae33e98d89b0278=function() local MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 if (MiDKPMemberPickerFrame.unused_buttons[1]) then MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = MiDKPMemberPickerFrame.unused_buttons[1]; table.remove(MiDKPMemberPickerFrame.unused_buttons, 1); table.insert(MiDKPMemberPickerFrame.used_buttons, MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5); return MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5; end local name = "MiDKPMemberPickerFrameMember"..(MiDKPMemberPickerFrame.button_count + 1); MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = CreateFrame("CheckButton", name, MiDKPMemberPickerFrame, "MiDKPCheckButtonTemplate"); MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetScript("OnClick", MiDKP_UI.Util.CheckButton_OnClick); MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetWidth(150); MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetHeight(36); table.insert(MiDKPMemberPickerFrame.used_buttons, MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5); MiDKPMemberPickerFrame.button_count = MiDKPMemberPickerFrame.button_count + 1; return MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5; end local MiDKP_63e836599ae4bb6744ea911aa9fc5093=function() local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56; for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPMemberPickerFrame.used_buttons) do table.insert(MiDKPMemberPickerFrame.unused_buttons, MiDKP_8d0644c92128c1ff68223fd74ba63b56); end MiDKPMemberPickerFrame.used_buttons = {} end local MiDKP_53f16f3c3380ad50536b9d7438e5d644=function() local members = {} for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["members"]) do table.insert(members, MiDKP_63a9ce6f1eeac72ef41293b7d0303335); end table.sort(members); return members end local left = 10; local top = -10; local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56; local selected_members = {} MiDKP_63e836599ae4bb6744ea911aa9fc5093(); if MiDKPMemberPickerFrame.totalpoints then MiDKPMemberPickerFramePoint:EnableKeyboard(false) MiDKPMemberPickerFrameText:EnableKeyboard(false) else MiDKPMemberPickerFramePoint:EnableKeyboard(true) MiDKPMemberPickerFrameText:EnableKeyboard(true) end if not MiDKP_befe792f41e009c2804d4d8f78109f9e then if (MiDKPMemberPickerFrame.text) then MiDKPMemberPickerFrameText:SetText(MiDKPMemberPickerFrame.text); else MiDKPMemberPickerFrameText:SetText(""); end if (MiDKPMemberPickerFrame.point) then MiDKPMemberPickerFramePoint:SetText(MiDKPMemberPickerFrame.point); else MiDKPMemberPickerFramePoint:SetText(""); end if (MiDKPMemberPickerFrame.text) then MiDKPMemberPickerFramePoint:SetFocus(); MiDKPMemberPickerFramePoint:HighlightText(); else MiDKPMemberPickerFrameText:SetFocus(); MiDKPMemberPickerFrameText:HighlightText(); end end if MiDKP_befe792f41e009c2804d4d8f78109f9e then if (MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351) then if (MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351 == "first5") then local num = GetNumRaidMembers(); local index; for index = 1, num, 1 do local name, rank, subgroup, level, class, fileName, zone, online, isDead, role, isML = GetRaidRosterInfo(index); local MiDKP_272eafc4ce7ec507b8ba1aa5e255a021=online or MiDKP_Options["member_record_disconnected"] if (name and subgroup <= 5) then selected_members[name] = MiDKP_30b6f278098f3fa7bf562ea6d5620a66 and MiDKP_272eafc4ce7ec507b8ba1aa5e255a021 end end elseif (MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351 == "raid") then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["members"]) do local MiDKP_272eafc4ce7ec507b8ba1aa5e255a021=(MiDKP_8d0644c92128c1ff68223fd74ba63b56["online"] and MiDKP_8d0644c92128c1ff68223fd74ba63b56["online"]==1) or MiDKP_Options["member_record_disconnected"] if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["inraid"] == 1) then selected_members[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] = MiDKP_30b6f278098f3fa7bf562ea6d5620a66 and MiDKP_272eafc4ce7ec507b8ba1aa5e255a021; end end elseif (MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351 == "all") then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["members"]) do selected_members[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] = MiDKP_30b6f278098f3fa7bf562ea6d5620a66 end end end else if (MiDKPMemberPickerFrame.members) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPMemberPickerFrame.members) do selected_members[MiDKP_8d0644c92128c1ff68223fd74ba63b56] = true; end elseif (MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351) then if (MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351 == "first5") then local num = GetNumRaidMembers(); local index; for index = 1, num, 1 do local name, rank, subgroup, level, class, fileName, zone, online, isDead, role, isML = GetRaidRosterInfo(index); local MiDKP_272eafc4ce7ec507b8ba1aa5e255a021=onLine or MiDKP_Options["member_record_disconnected"] if (name and subgroup <= 5) then selected_members[name] = MiDKP_30b6f278098f3fa7bf562ea6d5620a66 and MiDKP_272eafc4ce7ec507b8ba1aa5e255a021 end end elseif (MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351 == "raid") then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["members"]) do local MiDKP_272eafc4ce7ec507b8ba1aa5e255a021=(MiDKP_8d0644c92128c1ff68223fd74ba63b56["online"] and MiDKP_8d0644c92128c1ff68223fd74ba63b56["online"]==1) or MiDKP_Options["member_record_disconnected"] if (MiDKP_8d0644c92128c1ff68223fd74ba63b56["inraid"] == 1) then selected_members[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] = MiDKP_30b6f278098f3fa7bf562ea6d5620a66 and MiDKP_272eafc4ce7ec507b8ba1aa5e255a021; end end elseif (MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351 == "all") then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(raid["members"]) do selected_members[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] = true; end end end end local MiDKP_9caaf8d40fae5eebbd51771e96608617=MiDKP_Config["running_raid"] local lines = 1; for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKP_53f16f3c3380ad50536b9d7438e5d644()) do local button = MiDKP_830674a0d2d9035ecae33e98d89b0278(); local text if (raid["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56]["class"])then text= MiDKP_Util:RenderText(MiDKP_8d0644c92128c1ff68223fd74ba63b56,MIDKP_CLASS[string.upper(raid["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56]["class"])].color) else text= MiDKP_8d0644c92128c1ff68223fd74ba63b56 end if (raid["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56]["inraid"] ~= 1 and MiDKP_9caaf8d40fae5eebbd51771e96608617) then text = text .. MIDKP_TEXT_AWAY; elseif (raid["members"][MiDKP_8d0644c92128c1ff68223fd74ba63b56]["online"] ~= 1 and MiDKP_9caaf8d40fae5eebbd51771e96608617) then text = text .. MIDKP_TEXT_OFFLINE; end button.name = MiDKP_8d0644c92128c1ff68223fd74ba63b56; left,top,lines=MiDKP_Util:CalculateCoord(left,top,lines); button:SetPoint("TOPLEFT", MiDKPMemberPickerFrameInnerFrame, "TOPLEFT", left, top); getglobal(button:GetName().."Text"):SetText(text) if (selected_members[MiDKP_8d0644c92128c1ff68223fd74ba63b56] ) then button:SetChecked(1); else button:SetChecked(0); end left = left + 180; button:Show(); end MiDKPMemberPickerFrame:SetWidth(600); MiDKPMemberPickerFrame:SetHeight(270 + lines * 24); MiDKPMemberPickerFrameInnerFrame:SetHeight(30 + lines * 24); for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPMemberPickerFrame.unused_buttons) do MiDKP_8d0644c92128c1ff68223fd74ba63b56:Hide(); end if MiDKPMemberPickerFrame.totalpoints then local member_size= MiDKP_UIHelp.Member.GetSelectedMembersSize() MiDKP_UIHelp.Member.SetAveragePoint(member_size) end end, GetSelectedMembersSize=function() local MiDKP_e914904fab9d05d3f54d52bfc31a0f3f local membersize=0 for MiDKP_e914904fab9d05d3f54d52bfc31a0f3f=1, MiDKPMemberPickerFrame.button_count,1 do local name = "MiDKPMemberPickerFrameMember"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f; if _G[name]:GetChecked() then membersize=membersize+1 end end return membersize end, SetAveragePoint=function (membersize) if membersize==0 then return end if not MiDKPMemberPickerFrame.totalpoints then return end MiDKPMemberPickerFramePoint:SetText(string.twodigitfloat(MiDKPMemberPickerFrame.totalpoints/membersize)); end, DoUpdate=function() local raid = MiDKP_Core.Raid.GetCurrentRaid(); local MiDKP_5872af8c53c19a2665ed9942c461d8e5=function() local page = MiDKPMemberPage.page or 1; if (not raid) then MiDKPMemberPageDelete:Disable(); MiDKPMemberPageCreate:Disable(); MiDKPMemberPagePrevButton:Disable(); MiDKPMemberPageNextButton:Disable(); return; end if (raid["start"]) then MiDKPMemberPageCreate:Enable(); if (MiDKPMemberPage.index) then if (MiDKPMemberPage.index > (page - 1)*MIDKP_MEMBER_PAGE_COUNT) then MiDKPMemberPageDelete:Enable(); else MiDKPMemberPageDelete:Disable(); end else MiDKPMemberPageDelete:Disable(); end else MiDKPMemberPageCreate:Disable(); MiDKPMemberPageDelete:Disable(); end MiDKP_Widget.Panel().ListPanel("Member",MIDKP_MEMBER_PAGE_COUNT).UpdateButtons() MiDKP_Widget.Button(MiDKPMemberPagePrevButton).PrevButton().SetEnable() MiDKP_Widget.Button(MiDKPMemberPageNextButton).NextButton(MIDKP_MEMBER_PAGE_COUNT,MiDKP_Core.Raid.GetCurrentRaidSize).SetEnable() end local MiDKP_3fbf677a5a5f64ab5b3d22e350667649=function(MiDKP_e0744a0bff1e34800f14ca9a06b32530) MiDKP_Widget.Panel().SetButtons(MiDKP_e0744a0bff1e34800f14ca9a06b32530,"Member") end getglobal("MiDKPMemberPageColumnHeader1Name"):SetText(MIDKP_TEXT_SORT_NAME) getglobal("MiDKPMemberPageColumnHeader3Name"):SetText(MIDKP_TEXT_SORT_DKP) getglobal("MiDKPMemberPageColumnHeader4Name"):SetText(MIDKP_TEXT_SORT_TOTALDKP) local MiDKP_1ce596c35ff798172f104756561b3b8e=MiDKP_UIHelp.Member local MiDKP_e0744a0bff1e34800f14ca9a06b32530={} if (raid and raid["members"]) then local members=MiDKP_Core.Member.FilterSortMembers(raid["members"],MiDKP_1ce596c35ff798172f104756561b3b8e.currentsort,MiDKP_1ce596c35ff798172f104756561b3b8e.classfilter,MiDKP_1ce596c35ff798172f104756561b3b8e.sortby,raid["dkp"]) MiDKPMemberPage.count=table.getn(members) MiDKP_e0744a0bff1e34800f14ca9a06b32530=MiDKP_Core.Member.GetMembersByPage(members,MiDKPMemberPage.page or 1,raid,"member") end MiDKP_3fbf677a5a5f64ab5b3d22e350667649(MiDKP_e0744a0bff1e34800f14ca9a06b32530) MiDKP_5872af8c53c19a2665ed9942c461d8e5(); end, ShowAddMemberPage=function() local left = 10; local top = -10; local lines = 1; local notChecked=true for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MIDKP_CLASS.NAME) do local button = MiDKP_UIHelp.Member.GetClassButton(MiDKP_8d0644c92128c1ff68223fd74ba63b56); if notChecked then button:SetChecked(1) notChecked=false end left,top,lines=MiDKP_Util:CalculateCoord(left,top,lines); button:SetPoint("TOPLEFT", MiDKPAddMemberFrameInnerFrame, "TOPLEFT", left, top); getglobal(button:GetName().."Text"):SetText(MIDKP_CLASS[string.upper(MiDKP_8d0644c92128c1ff68223fd74ba63b56)].text1); left = left +78; button:Show(); end MiDKPAddMemberFrame:Show(); end, GetClassButton=function(MiDKP_b962f54280c77029bc350c2b321adc64) local name = "MiDKPAddMemberFrameClass"..MiDKP_b962f54280c77029bc350c2b321adc64; local button = CreateFrame("CheckButton", name, MiDKPAddMemberFrame, "MiDKPCheckButtonTemplate"); button.class=MiDKP_b962f54280c77029bc350c2b321adc64; button:SetScript("OnClick", MiDKP_UIHelp.Member.CheckButton_OnClick); button:SetWidth(80); button:SetHeight(36); table.insert(MiDKPAddMemberFrame.used_buttons, button); MiDKPAddMemberFrame.button_count = MiDKPAddMemberFrame.button_count + 1; return button; end, CheckButton_OnClick=function(ui_element) MiDKP_UI.Util.CheckButton_OnClick(ui_element); MiDKPAddMemberFrame.class=ui_element.class; end, } MiDKP_UIHelp.Item={ DoUpdate=function() local index = 1; local raid = MiDKP_Core.Raid.GetCurrentRaid(); local MiDKP_e0744a0bff1e34800f14ca9a06b32530={} if (raid and raid["items"]) then local MiDKP_63a9ce6f1eeac72ef41293b7d0303335; local page = MiDKPItemPage.page or 1; MiDKP_e0744a0bff1e34800f14ca9a06b32530= MiDKP_Core.Item.GetItemsByPage(raid,page) end MiDKP_UIHelp.Item.MiDKP_76f222cb2860c39f166797acb7467423(MiDKP_e0744a0bff1e34800f14ca9a06b32530) MiDKP_UIHelp.Item.MiDKP_5872af8c53c19a2665ed9942c461d8e5(); end, MiDKP_5872af8c53c19a2665ed9942c461d8e5=function() local page = MiDKPItemPage.page or 1; local raid = MiDKP_Core.Raid.GetCurrentRaid(); if (not raid) then MiDKPItemPageCreate:Disable(); MiDKPItemPageModify:Disable(); MiDKPItemPageDelete:Disable(); MiDKPItemPagePrevButton:Disable(); MiDKPItemPageNextButton:Disable(); return; end if (raid["start"]) then MiDKPItemPageCreate:Enable(); if (MiDKPItemPage.index) and (MiDKPItemPage.index > (page - 1)*MIDKP_ITEM_PAGE_COUNT) then MiDKPItemPageModify:Enable(); MiDKPItemPageDelete:Enable(); else MiDKPItemPageModify:Disable(); MiDKPItemPageDelete:Disable(); end else MiDKPItemPageCreate:Disable(); MiDKPItemPageModify:Disable(); MiDKPItemPageDelete:Disable(); end MiDKP_Widget.Panel().ListPanel("Item",MIDKP_ITEM_PAGE_COUNT).UpdateButtons() MiDKP_Widget.Button(MiDKPItemPagePrevButton).PrevButton().SetEnable() MiDKP_Widget.Button(MiDKPItemPageNextButton).NextButton(MIDKP_ITEM_PAGE_COUNT,MiDKP_Core.Util.GetItemCount).SetEnable() end, MiDKP_e2113f341a2469748127fd991368c73f=function(index) local id = MiDKP_Core.Util.GetID("item", index); if (id) then MiDKP_Core.Item.ModifyItem(index, nil, nil, MiDKPMemberPickerFrame.members); MiDKP_UIHelp.Item.DoUpdate(); end end, MiDKP_76f222cb2860c39f166797acb7467423=function(MiDKP_e0744a0bff1e34800f14ca9a06b32530) MiDKP_Widget.Panel().SetButtons(MiDKP_e0744a0bff1e34800f14ca9a06b32530,"Item") end, } MiDKP_UIHelp.IgnoreItem={ DoUpdate=function() local MiDKP_5f5e596f08e1c68d3069dac1c0c1a580 = MiDKP_Core.Item.GetNumIgnoreItems(); local MiDKP_e44b39ce9bf25a1e21828ed9b61c0365 = FauxScrollFrame_GetOffset(MiDKPIgnoreItemsFrameScrollFrame); local MiDKP_935200802c6b9f940519a1822a252c38 = MiDKP_UIHelp.IgnoreItem.GetSelectedIgnoreItem(); local MiDKP_d7284badcef25da2d384806a56a36197; local MiDKP_e914904fab9d05d3f54d52bfc31a0f3f; if (MiDKP_935200802c6b9f940519a1822a252c38 and MiDKP_935200802c6b9f940519a1822a252c38 <= MiDKP_Core.Item.GetNumIgnoreItems()) then MiDKPIgnoreItemsFrameDelete:Enable(); else MiDKPIgnoreItemsFrameDelete:Disable(); end for MiDKP_e914904fab9d05d3f54d52bfc31a0f3f = 1, 13, 1 do MiDKP_d7284badcef25da2d384806a56a36197 = MiDKP_e44b39ce9bf25a1e21828ed9b61c0365 + MiDKP_e914904fab9d05d3f54d52bfc31a0f3f; local MiDKP_e6955c64cf39bdb23dc86de1a9ec2117 = MiDKP_Core.Item.GetIgnoreItemInfo(MiDKP_d7284badcef25da2d384806a56a36197); getglobal("MiDKPIgnoreItemsFrameItem"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f.."Name"):SetText(MiDKP_e6955c64cf39bdb23dc86de1a9ec2117); local MiDKP_ca0de5e9ed087ac8d67ca8d417281946 = getglobal("MiDKPIgnoreItemsFrameItem"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f); MiDKP_ca0de5e9ed087ac8d67ca8d417281946:SetID(MiDKP_d7284badcef25da2d384806a56a36197); if ( MiDKP_d7284badcef25da2d384806a56a36197 == MiDKP_935200802c6b9f940519a1822a252c38) then MiDKP_ca0de5e9ed087ac8d67ca8d417281946:LockHighlight(); else MiDKP_ca0de5e9ed087ac8d67ca8d417281946:UnlockHighlight(); end if ( MiDKP_d7284badcef25da2d384806a56a36197 > MiDKP_5f5e596f08e1c68d3069dac1c0c1a580 ) then MiDKP_ca0de5e9ed087ac8d67ca8d417281946:Hide(); else MiDKP_ca0de5e9ed087ac8d67ca8d417281946:Show(); end end FauxScrollFrame_Update(MiDKPIgnoreItemsFrameScrollFrame, MiDKP_5f5e596f08e1c68d3069dac1c0c1a580, 13, 18); end, SetSelectedIgnoreItem=function(index) MiDKPIgnoreItemsFrame.select_item = index; end, GetSelectedIgnoreItem=function() return MiDKPIgnoreItemsFrame.select_item; end, } MiDKP_UIHelp.Notify={ SetAllNotifyButtonGlow=function() local MiDKP_0854e53d94ff991aa1550ad6c102f8ce=function() if (not MiDKP_40f5f7a768451fa1dfa8023792895928) then MiDKP_40f5f7a768451fa1dfa8023792895928 = 1; MiDKP_78f0ba6c0eb142981c21abc32a1defa9 = -0.025; end local MiDKP_3823513dacdc8a8eb3bceddb4d054b2e=function(MiDKP_e13a96a0ad2aafbc4af618967d6c0dc1) if (MiDKP_e13a96a0ad2aafbc4af618967d6c0dc1 < 0.1) then MiDKP_e13a96a0ad2aafbc4af618967d6c0dc1 = 0.1; MiDKP_78f0ba6c0eb142981c21abc32a1defa9 = 0.01; end if (MiDKP_e13a96a0ad2aafbc4af618967d6c0dc1 > 1) then MiDKP_e13a96a0ad2aafbc4af618967d6c0dc1 = 1; MiDKP_78f0ba6c0eb142981c21abc32a1defa9 = -0.01; end return MiDKP_e13a96a0ad2aafbc4af618967d6c0dc1 end MiDKP_40f5f7a768451fa1dfa8023792895928 =MiDKP_3823513dacdc8a8eb3bceddb4d054b2e(MiDKP_40f5f7a768451fa1dfa8023792895928 + MiDKP_78f0ba6c0eb142981c21abc32a1defa9) return MiDKP_40f5f7a768451fa1dfa8023792895928 end local MiDKP_e914904fab9d05d3f54d52bfc31a0f3f = 1; local MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = getglobal("MiDKPNotifyEventButton"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f); while (MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5) do if (MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:IsVisible()) then local glow = getglobal(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:GetName().."Glow"); glow:SetAlpha(MiDKP_0854e53d94ff991aa1550ad6c102f8ce()); end MiDKP_e914904fab9d05d3f54d52bfc31a0f3f = MiDKP_e914904fab9d05d3f54d52bfc31a0f3f + 1; MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = getglobal("MiDKPNotifyEventButton"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f); end end, arrangeNotifyButton=function(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5) if(not MiDKP_EventFrame) then MiDKP_UIHelp.Event.GetEventFrame(); end if (MiDKP_1c3a79678050872d2413d1daaaaff9a2) then MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetPoint("RIGHT", MiDKP_1c3a79678050872d2413d1daaaaff9a2, "LEFT", 0, 0); MiDKP_1c3a79678050872d2413d1daaaaff9a2 = MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5; else MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetPoint("BOTTOMRIGHT", MiDKP_EventFrame, "BOTTOMRIGHT", -10, 10); MiDKP_1c3a79678050872d2413d1daaaaff9a2 = MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5; end end, AddNotify=function(MiDKP_e78d229014c7a07be65fde4797b92c86, MiDKP_8d0febf2348ea712b2b375ae95601d5f) local MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5; if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "event") then MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5= MiDKP_UIHelp.Event.GetEventButton("Boss"); else MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5= MiDKP_UIHelp.Event.GetEventButton("Item"); end if (MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5) then MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5.id = MiDKP_8d0febf2348ea712b2b375ae95601d5f; MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5.category = MiDKP_e78d229014c7a07be65fde4797b92c86; local MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af = MiDKP_Core.Raid.GetCurrentRaid(); if (MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af) then if (MiDKP_e78d229014c7a07be65fde4797b92c86 == "event") then MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5.text = MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["events"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["desc"]; else MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5.text = MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["items"][MiDKP_8d0febf2348ea712b2b375ae95601d5f]["item"]; end else MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5.text = nil; end MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:Show(); MiDKP_UIHelp.Notify.arrangeNotifyButton(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5); end end, SetNotifyLocation=function(ui_element) local _, MiDKP_14bd3b46801c67a61cdc231d79a52920 = ui_element:GetPoint(); if (MiDKP_14bd3b46801c67a61cdc231d79a52920) then local MiDKP_e914904fab9d05d3f54d52bfc31a0f3f = 1; local MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = getglobal("MiDKPNotifyEventButton"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f); while (MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5) do if (MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:IsVisible() and MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 ~= ui_element) then local _, MiDKP_6880771867790c20a71b359c6ce85efe = MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:GetPoint(); if (MiDKP_6880771867790c20a71b359c6ce85efe == ui_element) then if (MiDKP_14bd3b46801c67a61cdc231d79a52920 == MiDKP_EventFrame) then MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:ClearAllPoints(); MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetPoint("BOTTOMRIGHT", MiDKP_EventFrame, "BOTTOMRIGHT", -10, 10); else MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:ClearAllPoints(); MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetPoint("RIGHT", MiDKP_14bd3b46801c67a61cdc231d79a52920, "LEFT", 0, 0); end end end MiDKP_e914904fab9d05d3f54d52bfc31a0f3f = MiDKP_e914904fab9d05d3f54d52bfc31a0f3f + 1; MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = getglobal("MiDKPNotifyEventButton"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f); end end if (MiDKP_1c3a79678050872d2413d1daaaaff9a2 == ui_element) then if (MiDKP_14bd3b46801c67a61cdc231d79a52920 == MiDKP_EventFrame) then MiDKP_1c3a79678050872d2413d1daaaaff9a2 = nil; else MiDKP_1c3a79678050872d2413d1daaaaff9a2 = MiDKP_14bd3b46801c67a61cdc231d79a52920; end end ui_element:Hide(); end, DeleteNotify=function(MiDKP_8d0febf2348ea712b2b375ae95601d5f) local MiDKP_e914904fab9d05d3f54d52bfc31a0f3f=1; local MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = getglobal("MiDKPNotifyEventButton"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f); while (MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5) do if (MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:IsVisible() and "@"..MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5.id == MiDKP_8d0febf2348ea712b2b375ae95601d5f) then MiDKP_UIHelp.Notify.SetNotifyLocation(MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5) return end MiDKP_e914904fab9d05d3f54d52bfc31a0f3f = MiDKP_e914904fab9d05d3f54d52bfc31a0f3f + 1; MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 = getglobal("MiDKPNotifyEventButton"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f); end end, } MiDKP_UIHelp.Util={ MainFrame_Enable=function(toggle) if (toggle) then MiDKPMainFrameDisableMask:Hide(); else MiDKPMainFrameDisableMask:Show(); end; end, OptionPage_Commit=function() if (MiDKPOptionPageQualityUncommon:GetChecked()) then MiDKP_Options["min_quality"] = 2; elseif (MiDKPOptionPageQualityRare:GetChecked()) then MiDKP_Options["min_quality"] = 3; elseif (MiDKPOptionPageQualityEpic:GetChecked()) then MiDKP_Options["min_quality"] = 4; elseif (MiDKPOptionPageQualityLegendary:GetChecked()) then MiDKP_Options["min_quality"] = 5; end if (MiDKPOptionPageWhisper:GetChecked()) then MiDKP_Options["whisper_command"] = MiDKPOptionPageWhisperEditBox:GetText(); else MiDKP_Options["whisper_command"] = ""; end if (MiDKPOptionPageHideWhisper:GetChecked()) then MiDKP_Options["hide_whisper_reply"] = true; else MiDKP_Options["hide_whisper_reply"] = nil; MiDKP_HiddenWhisper={} end if (MiDKPOptionPageEventActionNoAction:GetChecked()) then MiDKP_Options["default_action"] = "noaction"; elseif (MiDKPOptionPageEventActionTipOnly:GetChecked()) then MiDKP_Options["default_action"] = "notify"; elseif (MiDKPOptionPageEventActionShowEdit:GetChecked()) then MiDKP_Options["default_action"] = "edit"; end if (MiDKPOptionPageEventMemberFirst5:GetChecked()) then MiDKP_Options["default_member_filter"] = "first5"; elseif (MiDKPOptionPageEventMemberRaid:GetChecked()) then MiDKP_Options["default_member_filter"] = "raid"; elseif (MiDKPOptionPageEventMemberAll:GetChecked()) then MiDKP_Options["default_member_filter"] = "all"; end if (MiDKPOptionPageEventMemberDisconnected:GetChecked()) then MiDKP_Options["member_record_disconnected"] = true; else MiDKP_Options["member_record_disconnected"] = nil; end if MiDKPOptionPagePointsSplit:GetChecked() then MiDKP_Options["split_item_points"] = true; else MiDKP_Options["split_item_points"] = nil; end end, MiniButton_SetPosition=function() if (MiDKP_Config["minibtn_pos"]) then MiDKPMiniButton:ClearAllPoints(); MiDKPMiniButton:SetPoint("CENTER", Minimap, "CENTER", MiDKP_Config["minibtn_pos"][1], MiDKP_Config["minibtn_pos"][2]); else MiDKPMiniButton:ClearAllPoints(); MiDKPMiniButton:SetPoint("CENTER", UIParent, "CENTER", -152, -83); end end, PagePreButtonClick=function(ui_element,callback) local MiDKP_1346009d8936868590c1d007e3efcfae = ui_element:GetParent(); if (not MiDKP_1346009d8936868590c1d007e3efcfae.page) then MiDKP_1346009d8936868590c1d007e3efcfae.page = 1; end if (MiDKP_1346009d8936868590c1d007e3efcfae.page > 1) then MiDKP_1346009d8936868590c1d007e3efcfae.page = MiDKP_1346009d8936868590c1d007e3efcfae.page - 1; callback(); end end, PageNextButtonClick=function(ui_element,MiDKP_3f50417fb16be9b1078eb68d24fa9c26,pagecount,callback) local MiDKP_1346009d8936868590c1d007e3efcfae = ui_element:GetParent(); if (not MiDKP_1346009d8936868590c1d007e3efcfae.page) then MiDKP_1346009d8936868590c1d007e3efcfae.page = 1; end if (MiDKP_1346009d8936868590c1d007e3efcfae.page * pagecount < MiDKP_3f50417fb16be9b1078eb68d24fa9c26) then MiDKP_1346009d8936868590c1d007e3efcfae.page = MiDKP_1346009d8936868590c1d007e3efcfae.page + 1; callback(); end end, UpdateButtonState=function() --[[if (MiDKPAnnounceFrameMembers:GetChecked()) then MiDKP_UIHelp.General.CheckButtonEnable(MiDKPAnnounceFrameMemberAll); MiDKP_UIHelp.General.CheckButtonEnable(MiDKPAnnounceFrameMemberClass); MiDKP_UIHelp.General.CheckButtonEnable(MiDKPAnnounceFrameMemberArmor); if (MiDKPAnnounceFrameMemberClass:GetChecked()) then MiDKP_UIHelp.General.CheckButtonListEnable("MiDKPAnnounceFrameMember",MIDKP_CLASS.NAME); else MiDKP_UIHelp.General.CheckButtonListDisable("MiDKPAnnounceFrameMember",MIDKP_CLASS.NAME); end if (MiDKPAnnounceFrameMemberArmor:GetChecked()) then MiDKP_UIHelp.General.CheckButtonListEnable("MiDKPAnnounceFrameMember",MIDKP_ARMOR.NAME); else MiDKP_UIHelp.General.CheckButtonListDisable("MiDKPAnnounceFrameMember",MIDKP_ARMOR.NAME); end else MiDKP_UIHelp.General.CheckButtonDisable(MiDKPAnnounceFrameMemberAll); MiDKP_UIHelp.General.CheckButtonDisable(MiDKPAnnounceFrameMemberClass); MiDKP_UIHelp.General.CheckButtonDisable(MiDKPAnnounceFrameMemberArmor); MiDKP_UIHelp.General.CheckButtonListDisable("MiDKPAnnounceFrameMember",MIDKP_ARMOR.NAME); MiDKP_UIHelp.General.CheckButtonListDisable("MiDKPAnnounceFrameMember",MIDKP_CLASS.NAME); end]] end, GetAnnounceConfig=function() local channel,event,item,member if (MiDKPAnnounceFrame.raidchannel) then channel = "RAID" elseif(MiDKPAnnounceFrame.guildchannel)then channel = "GUILD" elseif(MiDKPAnnounceFrame.officerchannel)then channel="OFFICER" elseif(MiDKPAnnounceFrame.partychannel)then channel="PARTY" end if (MiDKPAnnounceFrame.event) then event = true end if (MiDKPAnnounceFrame.item) then item = true end if (MiDKPAnnounceFrame.members) then member=true end return channel,event,item,member end, UpdateSortStatus=function(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3,MiDKP_1346009d8936868590c1d007e3efcfae) if(not MiDKP_1346009d8936868590c1d007e3efcfae.sortby[MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3])then return end MiDKP_1346009d8936868590c1d007e3efcfae.currentsort=MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3 if (MiDKP_1346009d8936868590c1d007e3efcfae.sortby[MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3]=="asc")then MiDKP_1346009d8936868590c1d007e3efcfae.sortby[MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3]="des" else MiDKP_1346009d8936868590c1d007e3efcfae.sortby[MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3]="asc" end end, SetItemRef=function(link, text, button) if (MiDKPMemberPickerFrame and MiDKPMemberPickerFrame:IsVisible() and MiDKPMemberPickerFrameText:HasFocus()) then local _, MiDKP_15ad1e501e228eb80be1cc7800ab967d= GetItemInfo(link) if MiDKP_15ad1e501e228eb80be1cc7800ab967d then MiDKPMemberPickerFrameText:SetText(MiDKPMemberPickerFrameText:GetText()..MiDKP_15ad1e501e228eb80be1cc7800ab967d) else MiDKP_Old_SetItemRef(link, text, button) end else MiDKP_Old_SetItemRef(link, text, button) end end, ChatEdit_InsertLink=function(text) if (MiDKPMemberPickerFrame and MiDKPMemberPickerFrame:IsVisible() and MiDKPMemberPickerFrameText:HasFocus()) then MiDKPMemberPickerFrameText:SetText(MiDKPMemberPickerFrameText:GetText()..text) else MiDKP_Old_ChatEdit_InsertLink(text) end end, GetDKPSetButton=function() local name = "MiDKPAnnounceFrameDKP"..(MiDKPAnnounceFrame.button_count + 1); local button = CreateFrame("CheckButton", name, MiDKPAnnounceFrame, "MiDKPCheckButtonTemplate"); button:SetWidth(150); button:SetHeight(36); MiDKPAnnounceFrame.button_count = MiDKPAnnounceFrame.button_count + 1; return button; end, InitSuiteCheckButtons=function() local left = 10; local top = -10; local set={} local lines = 1; local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56; local MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = 0; if (MiDKPData and MiDKPData["dkp"]) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPData["dkp"]) do table.insert(set, MiDKP_8d0644c92128c1ff68223fd74ba63b56["name"]); end end; local MiDKP_5f68f4546a1c234d1762b1a79d966267={} if (set) then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(set) do local button = MiDKP_UIHelp.Util.GetDKPSetButton(); local text = MiDKP_8d0644c92128c1ff68223fd74ba63b56; button.text = MiDKP_8d0644c92128c1ff68223fd74ba63b56; left,top,lines=MiDKP_Util:CalculateCoord(left,top,lines); button:SetPoint("TOPLEFT", MiDKPAnnounceFrameInnerFrame, "TOPLEFT", left, top-207); getglobal(button:GetName().."Text"):SetText(text); button.text = text; left = left + 180; MiDKP_5f68f4546a1c234d1762b1a79d966267[MiDKP_3f50417fb16be9b1078eb68d24fa9c26+1]=true button:Show(); MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_3f50417fb16be9b1078eb68d24fa9c26 + 1; end end MiDKP_Options["suites"]=MiDKP_Options["suites"] or MiDKP_5f68f4546a1c234d1762b1a79d966267 end, SetSuites=function() MiDKPAnnounceFrame.selectedSuite=MiDKP_Core.Raid.GetSuites() for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKPAnnounceFrame.selectedSuite) do if not _G["MiDKPAnnounceFrameDKP"..MiDKP_63a9ce6f1eeac72ef41293b7d0303335] then return end if MiDKP_8d0644c92128c1ff68223fd74ba63b56 then _G["MiDKPAnnounceFrameDKP"..MiDKP_63a9ce6f1eeac72ef41293b7d0303335]:SetChecked(1) else _G["MiDKPAnnounceFrameDKP"..MiDKP_63a9ce6f1eeac72ef41293b7d0303335]:SetChecked(0) end end end, GetSuites=function() local MiDKP_5f68f4546a1c234d1762b1a79d966267={} for MiDKP_e914904fab9d05d3f54d52bfc31a0f3f=1,MiDKPAnnounceFrame.button_count,1 do if (_G["MiDKPAnnounceFrameDKP"..MiDKP_e914904fab9d05d3f54d52bfc31a0f3f]:GetChecked()) then MiDKP_5f68f4546a1c234d1762b1a79d966267[MiDKP_e914904fab9d05d3f54d52bfc31a0f3f]=true else MiDKP_5f68f4546a1c234d1762b1a79d966267[MiDKP_e914904fab9d05d3f54d52bfc31a0f3f]=false end end return MiDKP_5f68f4546a1c234d1762b1a79d966267 end, RightButtonUp=function(self,button,MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3) local menuList = {} if MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3=="member" then menuList = { { text = MIDKP_TEXT_ADD_EVENT, func = MiDKP_UI.Member.CreateButton_OnClick}, { text = MIDKP_TEXT_DELETE, func = MiDKP_UI.Member.DeleteButton_OnClick }, } elseif MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3=="event" then menuList = { { text = MIDKP_TEXT_MODIFY, func = MiDKP_UI.Event.ModifyButton_OnClick}, { text = MIDKP_TEXT_DELETE, func = MiDKP_UI.Event.DeleteButton_OnClick }, } elseif MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3=="item" then menuList = { { text = MIDKP_TEXT_MODIFY_ITEM, func = MiDKP_UI.Item.ModifyButton_OnClick }, { text = MIDKP_TEXT_DELETE, func = MiDKP_UI.Item.DeleteButton_OnClick }, { text = MIDKP_TEXT_ADD_TO_LIST, func = MiDKP_UI.Item.AddToListButton_OnClick }, } elseif MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3=="dkp" then menuList = { { text = MIDKP_TEXT_ANNOUNCE_PLAYER_PERSON, func = MiDKP_UI.DKP.SendDKPToPerson_OnClick }, { text = MIDKP_TEXT_ANNOUNCE_PLAYER_PARTY, func = MiDKP_UI.DKP.SendDKPToParty_OnClick }, { text = MIDKP_TEXT_ANNOUNCE_PLAYER_GUILD, func = MiDKP_UI.DKP.SendDKPToGuild_OnClick }, { text = MIDKP_TEXT_ANNOUNCE_PLAYER_RAID, func = MiDKP_UI.DKP.SendDKPToRaid_OnClick }, } else return end EasyMenu(menuList, MiDKPRightMouseMenuFrame, "cursor", 0 , 0, "MENU") end, } MiDKP_UIHelp.DKP={ sortby={ name="asc", class="asc", dkp="asc", totaldkp="asc" }, status={}, currentsort="name", filter={dkp=0}, DoUpdate=function() local MiDKP_6df89a1769aac2a96a6eedac25abfb37=function(MiDKP_a00724ebfb071ad7332b17a872f4f736) local MiDKP_f9870db166c2afe5471582af402d98c2={} if (not MiDKP_a00724ebfb071ad7332b17a872f4f736) then return end local MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af = MiDKP_Core.Raid.GetCurrentRaid() if not MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af then return MiDKP_f9870db166c2afe5471582af402d98c2 end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_a00724ebfb071ad7332b17a872f4f736) do if MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"][MiDKP_63a9ce6f1eeac72ef41293b7d0303335] and MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"][MiDKP_63a9ce6f1eeac72ef41293b7d0303335]["inraid"]==1 then MiDKP_f9870db166c2afe5471582af402d98c2[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]=MiDKP_8d0644c92128c1ff68223fd74ba63b56 end end return MiDKP_f9870db166c2afe5471582af402d98c2 end local MiDKP_1ce596c35ff798172f104756561b3b8e=MiDKP_UIHelp.DKP local MiDKP_e0744a0bff1e34800f14ca9a06b32530={} local MiDKP_f9542af0fc240db769f6a4369804f562={} local MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af local MiDKP_fe9676ca42761a2a83ddd72841fa0cef if(MiDKP_1ce596c35ff798172f104756561b3b8e.filter["dkp"]==0)then MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af = MiDKP_Core.Raid.GetCurrentRaid() else MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af=MiDKP_Core.Util.DataGetRaidByIndex(MiDKP_1ce596c35ff798172f104756561b3b8e.filter["dkp"]) end if(MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af and MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["members"])then MiDKP_f9542af0fc240db769f6a4369804f562=MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af.members if MiDKP_Options["show_raid_only"]==1 then MiDKP_f9542af0fc240db769f6a4369804f562=MiDKP_6df89a1769aac2a96a6eedac25abfb37(MiDKP_f9542af0fc240db769f6a4369804f562) end MiDKP_fe9676ca42761a2a83ddd72841fa0cef=MiDKP_Core.Member.FilterSortMembers(MiDKP_f9542af0fc240db769f6a4369804f562,MiDKP_1ce596c35ff798172f104756561b3b8e.currentsort,MiDKP_1ce596c35ff798172f104756561b3b8e.filter,MiDKP_1ce596c35ff798172f104756561b3b8e.sortby,MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af["dkp"]) MiDKPDKPPage.count=table.getn(MiDKP_fe9676ca42761a2a83ddd72841fa0cef) MiDKPDKPPage.data=MiDKP_fe9676ca42761a2a83ddd72841fa0cef MiDKPDKPPage.showtype=MiDKP_1ce596c35ff798172f104756561b3b8e.filter["dkp"] if(MiDKP_1ce596c35ff798172f104756561b3b8e.filter["dkp"]==0)then MiDKP_e0744a0bff1e34800f14ca9a06b32530=MiDKP_Core.Member.GetMembersByPage(MiDKP_fe9676ca42761a2a83ddd72841fa0cef,MiDKPDKPPage.page or 1,MiDKP_b5ec3bd1f1909e6b5ef04493c27f77af,"dkp") else MiDKP_e0744a0bff1e34800f14ca9a06b32530=MiDKP_Core.DKP.GetDKPMembersByPage(MiDKP_fe9676ca42761a2a83ddd72841fa0cef,MiDKPDKPPage.page or 1,MiDKP_f9542af0fc240db769f6a4369804f562) end end MiDKP_UIHelp.DKP.SetDKPButtonList(MiDKP_e0744a0bff1e34800f14ca9a06b32530) MiDKP_UIHelp.DKP.updateButtons(); end, SetDKPButtonList=function(MiDKP_e0744a0bff1e34800f14ca9a06b32530) MiDKP_Widget.Panel().SetButtons(MiDKP_e0744a0bff1e34800f14ca9a06b32530,"DKP") end, updateButtons=function() local page = MiDKPDKPPage.page or 1; local raid = MiDKP_Core.Raid.GetCurrentRaid(); if (not raid) then else MiDKP_Widget.Panel().ListPanel("DKP",MIDKP_DKP_PAGE_COUNT).UpdateButtons() end MiDKP_Widget.Button(MiDKPDKPPagePrevButton).PrevButton().SetEnable() MiDKP_Widget.Button(MiDKPDKPPageNextButton).NextButton(MIDKP_DKP_PAGE_COUNT,MiDKP_Core.DKP.GetCurrentDataSize).SetEnable() end, DropDownClassInit=function() MiDKP_Widget.DDList(MiDKP_UIHelp.DKP.DoUpdate,MiDKP_UIHelp.DKP.filter,MiDKP_UIHelp.DKP.status,MiDKPDKPPage).Class().DropDownInit() end, DropDownDKPInit=function() MiDKP_Widget.DDList(MiDKP_UIHelp.DKP.DoUpdate,MiDKP_UIHelp.DKP.filter,MiDKP_UIHelp.DKP.status,MiDKPDKPPage).DKP().DropDownInit() end, } MiDKP_Util={} function MiDKP_Util:GetPoint(point, noinfo) if (type(point) == "string") then if (not string.find(point, "^([%+%-%.0-9]+)$")) then if (not noinfo) then MiDKP_Util:Print("error", MIDKP_TEXT_INVALID_POINT) end return end point = tonumber(point) elseif (type(point) ~= "number") then return end return point end function MiDKP_Util:SplitString(szFullString, szSeparator) local nFindStartIndex = 1 local nSplitIndex = 1 local nSplitArray = {} while true do local nFindLastIndex = string.find(szFullString, szSeparator, nFindStartIndex) if not nFindLastIndex then nSplitArray[nSplitIndex] = string.sub(szFullString, nFindStartIndex, string.len(szFullString)) break end nSplitArray[nSplitIndex] = string.sub(szFullString, nFindStartIndex, nFindLastIndex - 1) nFindStartIndex = nFindLastIndex + string.len(szSeparator) nSplitIndex = nSplitIndex + 1 end return nSplitArray end function MiDKP_Util:String2Pattern(MiDKP_acd18e5e4cc047ed8d218397986e9dc2) MiDKP_acd18e5e4cc047ed8d218397986e9dc2 = string.gsub(MiDKP_acd18e5e4cc047ed8d218397986e9dc2, "%(", "%%(") MiDKP_acd18e5e4cc047ed8d218397986e9dc2 = string.gsub(MiDKP_acd18e5e4cc047ed8d218397986e9dc2, "%)", "%%)") MiDKP_acd18e5e4cc047ed8d218397986e9dc2 = string.gsub(MiDKP_acd18e5e4cc047ed8d218397986e9dc2, "%%s", "(.-)") MiDKP_acd18e5e4cc047ed8d218397986e9dc2 = string.gsub(MiDKP_acd18e5e4cc047ed8d218397986e9dc2, "%%d", "(%%d+)") return MiDKP_acd18e5e4cc047ed8d218397986e9dc2 end function MiDKP_Util:GetRaidMemberSnapshot() local info = {} local name, rank, subgroup, level, class, fileName, zone, online, isDead, role, isML local num = GetNumRaidMembers() for i = 1, num, 1 do name, rank, subgroup, level, class, fileName, zone, online, isDead, role, isML = GetRaidRosterInfo(i) if (name) then info[name] = {} info[name]["name"]= name info[name]["class"] = fileName info[name]["lclass"] = class info[name]["group"] = subgroup info[name]["zone"] = zone info[name]["online"] = online end end return info end function MiDKP_Util:GetTimeStamp() local _, month, day, year = CalendarGetDate() local hour, minute = GetGameTime() local timevalue = (year - 2000) * 60 * 60 * 365 + month * tonumber(string.format("%04d%02d%02d%02d%02d", year, month, day, hour, minute)) local timestring = string.format("%04d.%02d.%02d %02d:%02d", year, month, day, hour, minute) return {timestring, timevalue} end function MiDKP_Util:JoinString(tbl, sep) if (not sep) then sep = " " end local MiDKP_acd18e5e4cc047ed8d218397986e9dc2 = "" local i, MiDKP_8d0644c92128c1ff68223fd74ba63b56 if (tbl) then for i, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(tbl) do MiDKP_acd18e5e4cc047ed8d218397986e9dc2 = MiDKP_acd18e5e4cc047ed8d218397986e9dc2 .. MiDKP_8d0644c92128c1ff68223fd74ba63b56 .. sep end end if (string.len(MiDKP_acd18e5e4cc047ed8d218397986e9dc2) > 0) then return string.sub(MiDKP_acd18e5e4cc047ed8d218397986e9dc2, 1, string.len(MiDKP_acd18e5e4cc047ed8d218397986e9dc2) - string.len(sep)) end end function MiDKP_Util:GetTimeString(interval) local day, hour, minute, second local ret = "" day = math.floor(interval/86400) interval = interval - day * 86400 hour = math.floor(interval/3600) interval = interval - hour * 3600 minute = math.floor(interval/60) interval = interval - minute * 60 second = math.floor(interval) if (day > 0) then ret = ret .. day .. MIDKP_TEXT_DAY end if (hour > 0) then ret = ret .. hour .. MIDKP_TEXT_HOUR end if (minute > 0) then ret = ret .. minute .. MIDKP_TEXT_MINUTE end if (second > 0) then ret = ret .. second .. MIDKP_TEXT_SECOND end return ret end function MiDKP_Util:ParseRealText(MiDKP_e6955c64cf39bdb23dc86de1a9ec2117) MiDKP_e6955c64cf39bdb23dc86de1a9ec2117 = string.gsub(MiDKP_e6955c64cf39bdb23dc86de1a9ec2117, "<", "&lt") MiDKP_e6955c64cf39bdb23dc86de1a9ec2117 = string.gsub(MiDKP_e6955c64cf39bdb23dc86de1a9ec2117, ">", "&gt") MiDKP_e6955c64cf39bdb23dc86de1a9ec2117 = string.gsub(MiDKP_e6955c64cf39bdb23dc86de1a9ec2117, "|", "$") return MiDKP_e6955c64cf39bdb23dc86de1a9ec2117 end function MiDKP_Util:FindString(MiDKP_acd18e5e4cc047ed8d218397986e9dc2, MiDKP_a8858383576d7634cceceaf04a2ddb29) local MiDKP_8e0e84596da5717799a875d1aeeb63bc=function(s, e, ...) if (s and e) then return ... end end return MiDKP_8e0e84596da5717799a875d1aeeb63bc(string.find(MiDKP_acd18e5e4cc047ed8d218397986e9dc2, MiDKP_a8858383576d7634cceceaf04a2ddb29)) end function MiDKP_Util:FindItemLink(MiDKP_acd18e5e4cc047ed8d218397986e9dc2) local MiDKP_a2f3972c23a0aa3bd7fb0e9823d918f2,MiDKP_c2f245debd3efc045524792c222180d3,MiDKP_536473f22dedf9f29b94b1004a62b8a0 MiDKP_a2f3972c23a0aa3bd7fb0e9823d918f2,MiDKP_c2f245debd3efc045524792c222180d3,MiDKP_536473f22dedf9f29b94b1004a62b8a0= string.find(MiDKP_acd18e5e4cc047ed8d218397986e9dc2,"(|c%x+|Hitem:%d+:%-?%d+:%-?%d+:%-?%d+:%-?%d+:%-?%d+:%-?%d+:%-?%d+:%-?%d+|h%[.+%]|h|r).*") if(MiDKP_a2f3972c23a0aa3bd7fb0e9823d918f2 and MiDKP_c2f245debd3efc045524792c222180d3)then return MiDKP_536473f22dedf9f29b94b1004a62b8a0 end end function MiDKP_Util:ParseItemLink(link) if (link) then for id, name in string.gmatch(link, "|c%x+|Hitem:(%d+):%-?%d+:%-?%d+:%-?%d+:%-?%d+:%-?%d+:%-?%d+:%-?%d+:%-?%d+|h%[(.+)%]|h|r") do return tonumber(id), name end end end function MiDKP_Util:Print(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3, msg, ...) local message = string.format(msg, ...) local color = {} if (message) then if (MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3 == "info") then message = MIDKP_MESSAGE_INFO .. message elseif (MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3 == "error") then message = MIDKP_MESSAGE_ERROR .. message elseif (MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3 == "debug") then message = MIDKP_MESSAGE_DEBUG .. message end if (message) then DEFAULT_CHAT_FRAME:AddMessage(message, 1.0, 0.82, 0.0) end end end function MiDKP_Util:RenderText(text, color) if(not color) or (not text) or type(text)=='table' or type(color)=='table' then return "" end return "|"..color..text.."|r" end function MiDKP_Util:CompareMember(snapshot_old,snapshot_new) local MiDKP_e914904fab9d05d3f54d52bfc31a0f3f=0 for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(snapshot_new) do MiDKP_e914904fab9d05d3f54d52bfc31a0f3f=MiDKP_e914904fab9d05d3f54d52bfc31a0f3f+1 end if MiDKP_e914904fab9d05d3f54d52bfc31a0f3f==0 then return nil,"OTHER" end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs (snapshot_old) do if(not snapshot_new[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]) then return snapshot_old[MiDKP_63a9ce6f1eeac72ef41293b7d0303335],"LEAVE" end end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs (snapshot_new) do if(not snapshot_old[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]) then return snapshot_new[MiDKP_63a9ce6f1eeac72ef41293b7d0303335],"JOIN" end end return nil,"OTHER" end function MiDKP_Util:CalculateCoord(left,top,lines) if (left >= 550) then top = top - 24 left = 10 lines = lines + 1 end return left,top,lines end function MiDKP_Util:IsTableNotEmpty(MiDKP_49ccc92cd1bef60d860c1c7f84aaab89) return (MiDKP_Util:Size(MiDKP_49ccc92cd1bef60d860c1c7f84aaab89)>0) end function MiDKP_Util:Size(MiDKP_49ccc92cd1bef60d860c1c7f84aaab89) local MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = 0 local MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKP_49ccc92cd1bef60d860c1c7f84aaab89) do MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_3f50417fb16be9b1078eb68d24fa9c26 + 1 end if(MiDKP_3f50417fb16be9b1078eb68d24fa9c26==0)then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_49ccc92cd1bef60d860c1c7f84aaab89) do MiDKP_3f50417fb16be9b1078eb68d24fa9c26 = MiDKP_3f50417fb16be9b1078eb68d24fa9c26 + 1 end end return MiDKP_3f50417fb16be9b1078eb68d24fa9c26 end function MiDKP_Util:deleteItem(MiDKP_49ccc92cd1bef60d860c1c7f84aaab89,MiDKP_2e00ffac12aadb3a1fd865993ec505b9) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_49ccc92cd1bef60d860c1c7f84aaab89) do if(MiDKP_49ccc92cd1bef60d860c1c7f84aaab89[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]==MiDKP_2e00ffac12aadb3a1fd865993ec505b9) then table.remove(MiDKP_49ccc92cd1bef60d860c1c7f84aaab89,MiDKP_63a9ce6f1eeac72ef41293b7d0303335) return MiDKP_2e00ffac12aadb3a1fd865993ec505b9; end end return; end function MiDKP_Util:IsValidName(MiDKP_8983c60d66c8593ec7165ea9dbedb584) if string.find(MiDKP_8983c60d66c8593ec7165ea9dbedb584,"-") then return false else return true end end function MiDKP_Util:GetElementPoint(MiDKP_3dd3a8c252f84116a66a3f544fc4b71b) if type(MiDKP_3dd3a8c252f84116a66a3f544fc4b71b)=="number"then return MiDKP_3dd3a8c252f84116a66a3f544fc4b71b or 0 else return MiDKP_3dd3a8c252f84116a66a3f544fc4b71b and (MiDKP_3dd3a8c252f84116a66a3f544fc4b71b.point or MiDKP_3dd3a8c252f84116a66a3f544fc4b71b.score )or 0 end end function MiDKP_Util:GetElementClass(MiDKP_3dd3a8c252f84116a66a3f544fc4b71b) if type(MiDKP_3dd3a8c252f84116a66a3f544fc4b71b)=="number"then return "" else return (MiDKP_3dd3a8c252f84116a66a3f544fc4b71b and MiDKP_3dd3a8c252f84116a66a3f544fc4b71b.class) or "" end end string.firstupper=function(MiDKP_4c5e2a6c497f2639f1590edb13036a7d) return select(1,string.gsub(MiDKP_4c5e2a6c497f2639f1590edb13036a7d,"([a-zA-Z])",function(_s)return string.upper(_s)end,1)) end string.twodigitfloat=function(MiDKP_f4e13e8ecf20422833dd2d694a22bf40) return string.format("%d",MiDKP_f4e13e8ecf20422833dd2d694a22bf40*100)/100 end function MiDKP_Util:SafePopup_Show(MiDKP_8983c60d66c8593ec7165ea9dbedb584,...) if not UnitIsDeadOrGhost(UnitName("player")) then StaticPopup_Show(MiDKP_8983c60d66c8593ec7165ea9dbedb584,...) MiDKP_UIHelp.Util.MainFrame_Enable(false) else MiDKP_Util:Print("error",MIDKP_TEXT_PLAYER_DEAD) end end MiDKP_Widget={} local MiDKP_DDListData={ All=1, Cloth=9, Plate=5, Mail=2, Leather=13, UNKNOWN=16, MAGE=10, PRIEST=11, WARLOCK=12, ROGUE=15, DRUID=14, HUNTER=4, SHAMAN=3, WARRIOR=6, PALADIN=8, DEATHKNIGHT=7, } function MiDKP_Widget.DDList(MiDKP_b96d1a3c0528632466e59adade6f6c20,MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351,MiDKP_91f32deddbb8710fd941b684b1de8e6c,MiDKP_1346009d8936868590c1d007e3efcfae) local self={ update=MiDKP_b96d1a3c0528632466e59adade6f6c20, filter=MiDKP_1d5d5e28f21a78eec0db2c41dbfd6351, stats=MiDKP_91f32deddbb8710fd941b684b1de8e6c, parent=MiDKP_1346009d8936868590c1d007e3efcfae } local MiDKP_439c80e0cf16d48e7745bcd6bb223040=function(MiDKP_536473f22dedf9f29b94b1004a62b8a0) self.stats["used"]=1 if(not self.filter[MiDKP_536473f22dedf9f29b94b1004a62b8a0])then self.filter[MiDKP_536473f22dedf9f29b94b1004a62b8a0]=1 else self.filter[MiDKP_536473f22dedf9f29b94b1004a62b8a0]=nil end end local MiDKP_1b80d4fbbb6daa7d663925ebc4e6353c=function(MiDKP_e6955c64cf39bdb23dc86de1a9ec2117,MiDKP_536473f22dedf9f29b94b1004a62b8a0,MiDKP_7c5dc540b65cbf3818a27e763bad7e69,MiDKP_7697ad1db204832bf0b384b49b0f19cf,MiDKP_30b6f278098f3fa7bf562ea6d5620a66) info = {} info.keepShownOnClick=MiDKP_7697ad1db204832bf0b384b49b0f19cf info.text = MiDKP_e6955c64cf39bdb23dc86de1a9ec2117 info.value = MiDKP_536473f22dedf9f29b94b1004a62b8a0 info.checked=MiDKP_30b6f278098f3fa7bf562ea6d5620a66 info.func=function() MiDKP_7c5dc540b65cbf3818a27e763bad7e69(this.value) end UIDropDownMenu_AddButton(info) end local MiDKP_b962f54280c77029bc350c2b321adc64=function() local MiDKP_f77c93d6e2e537ffc5d3292568090320=function() if not (self.stats["used"])then self.filter["All"]=1 end MiDKP_1b80d4fbbb6daa7d663925ebc4e6353c(MIDKP_TEXT_ALL, "All", MiDKP_d9076c74c83250b859fd83c13bc942cc,1,self.filter["All"]) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MIDKP_ARMOR.CLASS) do if self.filter["All"] then self.filter[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]=1 end MiDKP_1b80d4fbbb6daa7d663925ebc4e6353c(MIDKP_ARMOR.TEXT[MiDKP_63a9ce6f1eeac72ef41293b7d0303335], MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_9f152fc07be92f45c12ccf8354786e5c,1,self.filter[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]) for MiDKP_b346ff9c8a9ef882088b9f1c82dabf17,MiDKP_1f767451a35d2d22ad352ee7ff068312 in pairs(MiDKP_8d0644c92128c1ff68223fd74ba63b56) do if self.filter[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] then self.filter[MiDKP_1f767451a35d2d22ad352ee7ff068312]=1 end MiDKP_1b80d4fbbb6daa7d663925ebc4e6353c("　"..MiDKP_Util:RenderText(MIDKP_CLASS[MiDKP_1f767451a35d2d22ad352ee7ff068312].text1,MIDKP_CLASS[MiDKP_1f767451a35d2d22ad352ee7ff068312].color), MiDKP_1f767451a35d2d22ad352ee7ff068312, MiDKP_cf9575e67a599893501c8665745532ae,1,self.filter[MiDKP_1f767451a35d2d22ad352ee7ff068312]) end end if self.filter["All"] then self.filter["UNKNOWN"]=1 end MiDKP_1b80d4fbbb6daa7d663925ebc4e6353c(MIDKP_TEXT_UNKNOWN, "UNKNOWN", MiDKP_3244ea21785a2d76bcf821e63a1554c4,1,self.filter["UNKNOWN"]) UIDropDownMenu_SetText(UIDropDownMenu_GetCurrentDropDown(),MIDKP_TEXT_CLASS) end local MiDKP_2474baa4891ad7431fb42c97134ad57d=function(MiDKP_14c80a48d7de9ab6f5fd0ec80344e3d9) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_DDListData) do if self.filter[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] then getglobal(MiDKP_14c80a48d7de9ab6f5fd0ec80344e3d9:GetParent():GetName().."Button"..MiDKP_8d0644c92128c1ff68223fd74ba63b56.."Check"):Show() else getglobal(MiDKP_14c80a48d7de9ab6f5fd0ec80344e3d9:GetParent():GetName().."Button"..MiDKP_8d0644c92128c1ff68223fd74ba63b56.."Check"):Hide() end end UIDropDownMenu_SetText(getglobal("MiDKPDKPPageColumnHeader3"),MiDKPData and MiDKPData["dkp"] and MiDKPData["dkp"][self.filter["dkp"]] and MiDKPData["dkp"][self.filter["dkp"]].name or MIDKP_TEXT_DKP_TITLE) end hooksecurefunc("UIDropDownMenuButton_OnClick",MiDKP_2474baa4891ad7431fb42c97134ad57d) local MiDKP_6bfe5a5d13b37497de23410eb5c8907a=function() local MiDKP_4919422287ef094dce1deaba85fade3d=true for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_DDListData)do if MiDKP_63a9ce6f1eeac72ef41293b7d0303335~="All" then MiDKP_4919422287ef094dce1deaba85fade3d=self.filter[MiDKP_63a9ce6f1eeac72ef41293b7d0303335] end if not MiDKP_4919422287ef094dce1deaba85fade3d then break end end if MiDKP_4919422287ef094dce1deaba85fade3d then self.filter["All"]=1 else self.filter["All"]=nil end end MiDKP_d9076c74c83250b859fd83c13bc942cc=function(MiDKP_536473f22dedf9f29b94b1004a62b8a0) MiDKP_439c80e0cf16d48e7745bcd6bb223040(MiDKP_536473f22dedf9f29b94b1004a62b8a0) if self.filter[MiDKP_536473f22dedf9f29b94b1004a62b8a0] then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_DDListData)do self.filter[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]=1 end else for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MiDKP_DDListData)do self.filter[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]=nil end end self.parent.page=1 self.update() end MiDKP_9f152fc07be92f45c12ccf8354786e5c=function(MiDKP_536473f22dedf9f29b94b1004a62b8a0) MiDKP_439c80e0cf16d48e7745bcd6bb223040(MiDKP_536473f22dedf9f29b94b1004a62b8a0) if self.filter[MiDKP_536473f22dedf9f29b94b1004a62b8a0] then for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MIDKP_ARMOR.CLASS[MiDKP_536473f22dedf9f29b94b1004a62b8a0]) do self.filter[MiDKP_8d0644c92128c1ff68223fd74ba63b56]=1 end else for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(MIDKP_ARMOR.CLASS[MiDKP_536473f22dedf9f29b94b1004a62b8a0]) do self.filter[MiDKP_8d0644c92128c1ff68223fd74ba63b56]=nil end end MiDKP_6bfe5a5d13b37497de23410eb5c8907a() self.parent.page=1 self.update() end MiDKP_cf9575e67a599893501c8665745532ae=function(MiDKP_536473f22dedf9f29b94b1004a62b8a0) MiDKP_439c80e0cf16d48e7745bcd6bb223040(MiDKP_536473f22dedf9f29b94b1004a62b8a0) if self.filter[MiDKP_536473f22dedf9f29b94b1004a62b8a0] then local MiDKP_3555f9561157c03e21be48d35228cffb=true for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MIDKP_ARMOR.CLASS[MIDKP_CLASS[MiDKP_536473f22dedf9f29b94b1004a62b8a0].PARENT]) do if not self.filter[MiDKP_8d0644c92128c1ff68223fd74ba63b56] then MiDKP_3555f9561157c03e21be48d35228cffb=false break end end if MiDKP_3555f9561157c03e21be48d35228cffb then self.filter[MIDKP_CLASS[MiDKP_536473f22dedf9f29b94b1004a62b8a0].PARENT]=1 end else self.filter[MIDKP_CLASS[MiDKP_536473f22dedf9f29b94b1004a62b8a0].PARENT]=nil end MiDKP_6bfe5a5d13b37497de23410eb5c8907a() self.parent.page=1 self.update() end MiDKP_3244ea21785a2d76bcf821e63a1554c4=function(MiDKP_536473f22dedf9f29b94b1004a62b8a0) MiDKP_439c80e0cf16d48e7745bcd6bb223040(MiDKP_536473f22dedf9f29b94b1004a62b8a0) MiDKP_6bfe5a5d13b37497de23410eb5c8907a() self.parent.page=1 self.update() end return{ DropDownInit=MiDKP_f77c93d6e2e537ffc5d3292568090320, } end local MiDKP_f8c6f4951c524600d5984ab47a0d8393=function() local MiDKP_ba42579468f0d5672717019f2489140b=function(MiDKP_536473f22dedf9f29b94b1004a62b8a0) self.filter["dkp"]=MiDKP_536473f22dedf9f29b94b1004a62b8a0 self.parent.page=1 self.update() end local MiDKP_b25d1d4813a6e9cb9fd1a65d83c52144=function() MiDKP_1b80d4fbbb6daa7d663925ebc4e6353c(MIDKP_TEXT_CURRENT_DKP,0,MiDKP_ba42579468f0d5672717019f2489140b,nil,self.filter["dkp"] ==0) if (not MiDKPData) or (not MiDKPData["dkp"]) then return end for MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_8d0644c92128c1ff68223fd74ba63b56 in ipairs(MiDKPData["dkp"]) do MiDKP_1b80d4fbbb6daa7d663925ebc4e6353c(MiDKP_8d0644c92128c1ff68223fd74ba63b56.name, MiDKP_63a9ce6f1eeac72ef41293b7d0303335, MiDKP_ba42579468f0d5672717019f2489140b, nil, (self.filter["dkp"] ==MiDKP_63a9ce6f1eeac72ef41293b7d0303335)) end UIDropDownMenu_SetText( UIDropDownMenu_GetCurrentDropDown(),MiDKPData and MiDKPData["dkp"] and MiDKPData["dkp"][self.filter["dkp"]] and MiDKPData["dkp"][self.filter["dkp"]].name or MIDKP_TEXT_DKP_TITLE) end return { DropDownInit=MiDKP_b25d1d4813a6e9cb9fd1a65d83c52144 } end return { Class=MiDKP_b962f54280c77029bc350c2b321adc64, DKP=MiDKP_f8c6f4951c524600d5984ab47a0d8393, } end function MiDKP_Widget.Button(MiDKP_14c80a48d7de9ab6f5fd0ec80344e3d9,MiDKP_b96d1a3c0528632466e59adade6f6c20) local self={ update=MiDKP_b96d1a3c0528632466e59adade6f6c20, ui=MiDKP_14c80a48d7de9ab6f5fd0ec80344e3d9 } local MiDKP_f5b2b4c6f1cb19f168e421abe6e02642=function() local MiDKP_1346009d8936868590c1d007e3efcfae = self.ui:GetParent(); local MiDKP_5c2f4d228a0acc6c32cd6bb30a981972=function() if (not MiDKP_1346009d8936868590c1d007e3efcfae.page) then MiDKP_1346009d8936868590c1d007e3efcfae.page = 1 end if (MiDKP_1346009d8936868590c1d007e3efcfae.page > 1) then MiDKP_1346009d8936868590c1d007e3efcfae.page = MiDKP_1346009d8936868590c1d007e3efcfae.page - 1 self.update() end end local MiDKP_fca5892ee59023345cdbe1cb5fcf1adb=function() if (not MiDKP_1346009d8936868590c1d007e3efcfae.page) or MiDKP_1346009d8936868590c1d007e3efcfae.page <= 1 then self.ui:Disable(); else self.ui:Enable(); end end return{ OnClick=MiDKP_5c2f4d228a0acc6c32cd6bb30a981972, SetEnable=MiDKP_fca5892ee59023345cdbe1cb5fcf1adb } end local MiDKP_1189e83102564b7039e5896816b192a9=function(MiDKP_3c75ed4b7dddc3634b4e670dc96de497,MiDKP_24fbd243c617fb810ae96b4946bf1113) local MiDKP_1346009d8936868590c1d007e3efcfae = self.ui:GetParent(); local MiDKP_5c2f4d228a0acc6c32cd6bb30a981972=function() if (not MiDKP_1346009d8936868590c1d007e3efcfae.page) then MiDKP_1346009d8936868590c1d007e3efcfae.page = 1; end local MiDKP_3f50417fb16be9b1078eb68d24fa9c26=MiDKP_1346009d8936868590c1d007e3efcfae.count or MiDKP_24fbd243c617fb810ae96b4946bf1113() or 0 if (MiDKP_1346009d8936868590c1d007e3efcfae.page * MiDKP_3c75ed4b7dddc3634b4e670dc96de497 < MiDKP_3f50417fb16be9b1078eb68d24fa9c26) then MiDKP_1346009d8936868590c1d007e3efcfae.page = MiDKP_1346009d8936868590c1d007e3efcfae.page + 1; self.update() end end local MiDKP_42c510b4d2a39af5d13fd7f36d52d6ef=function() local MiDKP_7193346511e6cfd5aa01fac54f2cd168=MiDKP_1346009d8936868590c1d007e3efcfae.page or 1 local MiDKP_3f50417fb16be9b1078eb68d24fa9c26=MiDKP_1346009d8936868590c1d007e3efcfae.count or MiDKP_24fbd243c617fb810ae96b4946bf1113() or 0 if (MiDKP_7193346511e6cfd5aa01fac54f2cd168 * MiDKP_3c75ed4b7dddc3634b4e670dc96de497 < MiDKP_3f50417fb16be9b1078eb68d24fa9c26) then self.ui:Enable(); else self.ui:Disable(); end end return{ OnClick=MiDKP_5c2f4d228a0acc6c32cd6bb30a981972, SetEnable=MiDKP_42c510b4d2a39af5d13fd7f36d52d6ef } end local MiDKP_a9a31f479b5a43b4d1b793cf400a8192=function(MiDKP_f850fe9b03931f56801e66ec6a7bc4a6,MiDKP_55d01b14fb85b0dc13cab5c5db12f249,MiDKP_ea57eedce088029fc0f53b3d905e41b3,...) local MiDKP_dcc12363403d44adcbc1024722cd50f7={...} local MiDKP_7763351e1012c04b995b64da33904ebf=function(args) for MiDKP_63a9ce6f1eeac72ef41293b7d0303335,MiDKP_8d0644c92128c1ff68223fd74ba63b56 in pairs(args) do local MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5=getglobal(self.ui:GetName()..MiDKP_63a9ce6f1eeac72ef41293b7d0303335) if not MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 then return end MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5:SetText(MiDKP_8d0644c92128c1ff68223fd74ba63b56) end end local MiDKP_bd44d627c4c6f371cdee5e2f30273a41=function(MiDKP_c947a4fd43f33304666b2655fad74dbf) if (MiDKP_c947a4fd43f33304666b2655fad74dbf) then MiDKP_UIHelp.General.CheckButtonListSetVerColor(self.ui:GetName(),MIDKP_LOCATIONS,1,1,1); MiDKP_UIHelp.General.CheckButtonListShow(self.ui:GetName(),MIDKP_LOCATIONS); for i=1,table.getn(MiDKP_dcc12363403d44adcbc1024722cd50f7)do getglobal(self.ui:GetName()..MiDKP_dcc12363403d44adcbc1024722cd50f7[i]):Show(); end self.ui:SetHeight(MiDKP_ea57eedce088029fc0f53b3d905e41b3); else MiDKP_UIHelp.General.CheckButtonListSetVerColor(self.ui:GetName(),MIDKP_LOCATIONS,0.5, 0.5, 0.5); if (MouseIsOver(self.ui)) then MiDKP_UIHelp.General.CheckButtonListShow(self.ui:GetName(),MIDKP_LOCATIONS); else MiDKP_UIHelp.General.CheckButtonListHide(self.ui:GetName(),MIDKP_LOCATIONS); end for i=1,table.getn(MiDKP_dcc12363403d44adcbc1024722cd50f7)do getglobal(self.ui:GetName()..MiDKP_dcc12363403d44adcbc1024722cd50f7[i]):Hide(); end self.ui:SetHeight(MiDKP_55d01b14fb85b0dc13cab5c5db12f249); end end local MiDKP_5678ac89437fda27247436c31bee789e=function() local MiDKP_1346009d8936868590c1d007e3efcfae = self.ui:GetParent(); local page = MiDKP_1346009d8936868590c1d007e3efcfae.page or 1; local index = (page - 1) * MiDKP_f850fe9b03931f56801e66ec6a7bc4a6 + self.ui:GetID(); MiDKP_bd44d627c4c6f371cdee5e2f30273a41(index==MiDKP_1346009d8936868590c1d007e3efcfae.index) end local MiDKP_5c2f4d228a0acc6c32cd6bb30a981972=function() local MiDKP_1346009d8936868590c1d007e3efcfae = self.ui:GetParent() local id = self.ui:GetID() local page = MiDKP_1346009d8936868590c1d007e3efcfae.page or 1 MiDKP_1346009d8936868590c1d007e3efcfae.index = (page - 1) * MiDKP_f850fe9b03931f56801e66ec6a7bc4a6 + id self.update() end local MiDKP_c864d872bdb8b313991e75a46aa43c83=function() local nameob = getglobal(self.ui:GetName().."Name") nameob:SetTextColor(1.0, 1.0, 1.0) MiDKP_5678ac89437fda27247436c31bee789e() end local MiDKP_141005fc028e4fb751b9fbdaeb99070f=function() local nameob = getglobal(self.ui:GetName().."Name") nameob:SetTextColor(NORMAL_FONT_COLOR.r, NORMAL_FONT_COLOR.g, NORMAL_FONT_COLOR.b) MiDKP_5678ac89437fda27247436c31bee789e() end return { SetVal=MiDKP_7763351e1012c04b995b64da33904ebf, OnClick=MiDKP_5c2f4d228a0acc6c32cd6bb30a981972, OnEnter=MiDKP_c864d872bdb8b313991e75a46aa43c83, OnLeave=MiDKP_141005fc028e4fb751b9fbdaeb99070f, Update=MiDKP_5678ac89437fda27247436c31bee789e, } end return { NextButton=MiDKP_1189e83102564b7039e5896816b192a9, PrevButton=MiDKP_f5b2b4c6f1cb19f168e421abe6e02642, ListButton=MiDKP_a9a31f479b5a43b4d1b793cf400a8192, } end function MiDKP_Widget.Panel(MiDKP_14c80a48d7de9ab6f5fd0ec80344e3d9) local self={ ui=MiDKP_14c80a48d7de9ab6f5fd0ec80344e3d9 } local MiDKP_17d930b99e470d5673f92b27d7bcbb69=function(MiDKP_e0744a0bff1e34800f14ca9a06b32530,MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3) local index=1 local page_size=getglobal("MIDKP_"..string.upper(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3).."_PAGE_COUNT") for MiDKP_63a9ce6f1eeac72ef41293b7d0303335 = 1, table.getn(MiDKP_e0744a0bff1e34800f14ca9a06b32530), 1 do local button = getglobal("MiDKP"..MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3.."Page"..MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3..index); button:Show(); MiDKP_Widget.Button(button).ListButton().SetVal(MiDKP_e0744a0bff1e34800f14ca9a06b32530[MiDKP_63a9ce6f1eeac72ef41293b7d0303335]) index=index+1 end local i; for i = index, page_size, 1 do local button = getglobal("MiDKP"..MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3.."Page"..MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3..i); button:Hide(); end end local MiDKP_90c825de921fb8499bb0d68f5ba8cf24=function(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3,MiDKP_7f76b97392e14a77389da8137cf91f2b) local MiDKP_5c536cd94ec0452c94e4b4c6d1f08d04=function(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3,MiDKP_8d0febf2348ea712b2b375ae95601d5f,MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7,MiDKP_2507e9f60d067a83b4e4c15eedc02239,MiDKP_1567433dc2669a08b64fcfd8872f2479,MiDKP_6b68f9a6f54b6291eed460dc6c13f6da,MiDKP_421bcbd81f579e88bce2f26c77cddcfd) local MiDKP_a0a053cacf1c8c43346fdc3adb684cb7=CreateFrame("CheckButton", self.ui:GetName()..MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3..tostring(MiDKP_8d0febf2348ea712b2b375ae95601d5f),self.ui, "MiDKP"..MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3.."ButtonTemplate") MiDKP_a0a053cacf1c8c43346fdc3adb684cb7:SetPoint(MiDKP_2507e9f60d067a83b4e4c15eedc02239,MiDKP_7dce5c33f0d4836b30c14f18b2fc43f7, MiDKP_1567433dc2669a08b64fcfd8872f2479,MiDKP_6b68f9a6f54b6291eed460dc6c13f6da,MiDKP_421bcbd81f579e88bce2f26c77cddcfd) MiDKP_a0a053cacf1c8c43346fdc3adb684cb7:SetID(MiDKP_8d0febf2348ea712b2b375ae95601d5f) return MiDKP_a0a053cacf1c8c43346fdc3adb684cb7 end local MiDKP_60293a1ee25af3b49dc7bcf3f116cae0=function(MiDKP_6b68f9a6f54b6291eed460dc6c13f6da,MiDKP_421bcbd81f579e88bce2f26c77cddcfd) local MiDKP_61b982a0c3b54f001631bc93ead995f6=MiDKP_5c536cd94ec0452c94e4b4c6d1f08d04(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3,1,self.ui,"TOPLEFT","TOPLEFT",(MiDKP_6b68f9a6f54b6291eed460dc6c13f6da or 25),(MiDKP_421bcbd81f579e88bce2f26c77cddcfd or -60)) for i =2,MiDKP_7f76b97392e14a77389da8137cf91f2b do local MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5=MiDKP_5c536cd94ec0452c94e4b4c6d1f08d04(MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3,i,MiDKP_61b982a0c3b54f001631bc93ead995f6,"TOP","BOTTOM",0,0) MiDKP_61b982a0c3b54f001631bc93ead995f6=MiDKP_99f3cf2c6f1fdfadb0fd4ab6e0843bf5 end end local MiDKP_ec3fe951c91bace205aad58e69912075=function() local i for i = 1, MiDKP_7f76b97392e14a77389da8137cf91f2b, 1 do local button = getglobal("MiDKP"..MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3.."Page"..MiDKP_6d5e7d83d8358745ae4dcf61d16bd1f3..i); button.widget.Update() end end return { AddButtons=MiDKP_60293a1ee25af3b49dc7bcf3f116cae0, UpdateButtons=MiDKP_ec3fe951c91bace205aad58e69912075 } end return { ListPanel=MiDKP_90c825de921fb8499bb0d68f5ba8cf24, SetButtons=MiDKP_17d930b99e470d5673f92b27d7bcbb69 } end 
